Hi Guys,
How to achieve the below schema where “attr” is totally dynamic and it varies according to the category of the Product,
According to the documentation,the only way i could see is using facets for the predicate attr.
Are the facets indexed ? Please clarify or help me achieve the design…
{
"name" : "Product Name",
"description" : "Description of the product",
"picture" : {
"lg" : "xxxxxxxx/prod-1577700854620-lg",
"md" : "xxxxxxxx/prod-1577700854620-md",
"sm" : "xxxxxxxx/prod-1577700854620-sm"
},
"gtin" : "",
"attr" : {
"nature" : {
"id" : "2",
"name" : "Natural"
},
"type" : {
"id" : "1",
"name" : "SEC"
},
"size" : {
"name" : "0,75 L",
"id" : "2"
},
"color" : {
"id" : "2",
"name" : "WHITE"
},
"ranking" : {
"id" : "1",
"name" : "AOC"
},
"year" : "2018",
"appelation" : "",
"grapes" : ""
},
"category_type" : "CATEGORY1",
"country" : {
"code" : "fr"
},
"producer" : {
"name" : "Producer Name",
"id" : ""
},
"createdby" : "root",
"createddate" : ISODate("2019-12-30T10:41:52.675Z"),
"modifiedby" : "root",
"modifieddate" : ISODate("2019-12-30T10:41:52.675Z")
}