Sharded, document oriented architecture means
NO JOINS
Parent-Child relationship
Introduced before 0.9
Not very famous/popular/obvious
Why?
Normalization of course!
Before
21 mln documents
53 Gb approx.
After
21 mln documents
6.6 Gb approx.
A WIN!
HOW?
"mappings":{
"company": {
"dynamic": false,
"properties": {
}
},
"product": {
"_all": {
"enabled": false
},
"_parent": {
"type": "company"
}
}
}
Blessings
Normalization
Constraints
Structured approach
DRAWBACKS 1
Create mappings at once
Same shard
Speed?
DRAWBACKS 2
Queries
Grandparent-parent-child-grandchild