| 1 |
15.51 ms |
Request:
{"index":"sw_product","search_type":"query_then_fetch","track_total_hits":true,"body":{"query":{"bool":{"filter":[{"bool":{"must":[{"bool":{"must":[{"term":{"active":true}},{"range":{"visibility_a4bd6d6716d64126bd5373aabee8c9af":{"gte":30}}}]}},{"term":{"categoryTree":"00000190787e7e7e7e7e7e7e7e7e0001"}},{"exists":{"field":"displayGroup"}},{"bool":{"should":[{"bool":{"must":[{"nested":{"path":"parent.swagDynamicAccessRules","query":{"terms":{"parent.swagDynamicAccessRules.id":["092cbf7d7bb845cf871f8bc35847021a","2cf59896af66475896ec8abd03ac26b6","3858957016644de4ae48c0500bf3ccc8","3c9d7d926b6a47fe8d4ae20d0a993424","69e0e90bd44d465989887976752efdfc","e1378db7808a478f919e0d740d5d6c1a","e92b366fe0ce497b9b5e2b4c2a2cb0f6","fa9feb38521b4c508af91afafcf89eaa","26d71577e36549c88b704bb9e7f73918","28caae75a5624f0d985abd0eb32aa160","53d34850dc394bd7806d5818c3011a2d","71012c3c5bf6413d83b96241e47bd9dd"]}}}},{"nested":{"path":"swagDynamicAccessRules","query":{"bool":{"must_not":[{"exists":{"field":"swagDynamicAccessRules.id"}}]}}}}]}},{"nested":{"path":"swagDynamicAccessRules","query":{"terms":{"swagDynamicAccessRules.id":["092cbf7d7bb845cf871f8bc35847021a","2cf59896af66475896ec8abd03ac26b6","3858957016644de4ae48c0500bf3ccc8","3c9d7d926b6a47fe8d4ae20d0a993424","69e0e90bd44d465989887976752efdfc","e1378db7808a478f919e0d740d5d6c1a","e92b366fe0ce497b9b5e2b4c2a2cb0f6","fa9feb38521b4c508af91afafcf89eaa","26d71577e36549c88b704bb9e7f73918","28caae75a5624f0d985abd0eb32aa160","53d34850dc394bd7806d5818c3011a2d","71012c3c5bf6413d83b96241e47bd9dd"]}}}},{"bool":{"must":[{"nested":{"path":"parent.swagDynamicAccessRules","query":{"bool":{"must_not":[{"exists":{"field":"parent.swagDynamicAccessRules.id"}}]}}}},{"nested":{"path":"swagDynamicAccessRules","query":{"bool":{"must_not":[{"exists":{"field":"swagDynamicAccessRules.id"}}]}}}}]}}]}}]}}],"should":[{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["72d6226071dd404ab1f06d8b5d3d4a4a"]}}}}]}},"boost":1500.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["c30a42724ae94c1490305b520504ad89"]}}}}]}},"boost":500.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["0d4166c09d074e87bca8f27a9667258e"]}}}}]}},"boost":1000.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["d4236e8075c24f0aa14fbc00e5a7d2cf"]}}}}]}},"boost":1400.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["fc6f7b2363f34eb0ac4ce8c8bc849c80"]}}}}]}},"boost":2700.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["4bc0ab1b83d14c7b8a78324aa8165c19"]}}}}]}},"boost":2500.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["c30a42724ae94c1490305b520504ad89"]}}}}]}},"boost":2500.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["24bd9ef97acf49abbc2ea0668540fd93"]}}}}]}},"boost":900.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["e5223b47a5704804b7a91ba0cf7606b4"]}}}}]}},"boost":5500.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["49cd6b6ce7a44c8fa0bfbba0a58a5a52"]}}}}]}},"boost":5300.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["5a53c9189d664a66975560870cf888d9"]}}}}]}},"boost":3600.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["f1dc6f55e42245c58da422fef72b020b"]}}}}]}},"boost":2500.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["d9d1d3476dfe49bba602149779907f13"]}}}}]}},"boost":1300.0}},{"constant_score":{"filter":{"bool":{"should":[{"nested":{"path":"streams","query":{"terms":{"streams.id":["5a71cb34bc2f4e9c844f827bacfd4e5e"]}}}}]}},"boost":600.0}}]}},"sort":[{"customFields.2fbb5fe2e29a4d70aa5854ce7ce3e20b.custom_fields_product_pseudopurchase":{"order":"DESC"}},{"_score":{"order":"DESC"}},{"markAsTopseller":{"order":"DESC"}},{"customFields.2fbb5fe2e29a4d70aa5854ce7ce3e20b.acris_search_sorting_relevance":{"order":"DESC"}},{"id":{"order":"ASC"}}],"aggregations":{"total-count":{"cardinality":{"field":"displayGroup"}}},"from":0,"size":24,"collapse":{"field":"displayGroup"},"timeout":"5s"}}
POST http://localhost:9200/sw_product/_search?search_type=query_then_fetch&track_total_hits=1
Accept: application/json
Content-Type: application/json
{
"query": {
"bool": {
"filter": [
{
"bool": {
"must": [
{
"bool": {
"must": [
{
"term": {
"active": true
}
},
{
"range": {
"visibility_a4bd6d6716d64126bd5373aabee8c9af": {
"gte": 30
}
}
}
]
}
},
{
"term": {
"categoryTree": "00000190787e7e7e7e7e7e7e7e7e0001"
}
},
{
"exists": {
"field": "displayGroup"
}
},
{
"bool": {
"should": [
{
"bool": {
"must": [
{
"nested": {
"path": "parent.swagDynamicAccessRules",
"query": {
"terms": {
"parent.swagDynamicAccessRules.id": [
"092cbf7d7bb845cf871f8bc35847021a",
"2cf59896af66475896ec8abd03ac26b6",
"3858957016644de4ae48c0500bf3ccc8",
"3c9d7d926b6a47fe8d4ae20d0a993424",
"69e0e90bd44d465989887976752efdfc",
"e1378db7808a478f919e0d740d5d6c1a",
"e92b366fe0ce497b9b5e2b4c2a2cb0f6",
"fa9feb38521b4c508af91afafcf89eaa",
"26d71577e36549c88b704bb9e7f73918",
"28caae75a5624f0d985abd0eb32aa160",
"53d34850dc394bd7806d5818c3011a2d",
"71012c3c5bf6413d83b96241e47bd9dd"
]
}
}
}
},
{
"nested": {
"path": "swagDynamicAccessRules",
"query": {
"bool": {
"must_not": [
{
"exists": {
"field": "swagDynamicAccessRules.id"
}
}
]
}
}
}
}
]
}
},
{
"nested": {
"path": "swagDynamicAccessRules",
"query": {
"terms": {
"swagDynamicAccessRules.id": [
"092cbf7d7bb845cf871f8bc35847021a",
"2cf59896af66475896ec8abd03ac26b6",
"3858957016644de4ae48c0500bf3ccc8",
"3c9d7d926b6a47fe8d4ae20d0a993424",
"69e0e90bd44d465989887976752efdfc",
"e1378db7808a478f919e0d740d5d6c1a",
"e92b366fe0ce497b9b5e2b4c2a2cb0f6",
"fa9feb38521b4c508af91afafcf89eaa",
"26d71577e36549c88b704bb9e7f73918",
"28caae75a5624f0d985abd0eb32aa160",
"53d34850dc394bd7806d5818c3011a2d",
"71012c3c5bf6413d83b96241e47bd9dd"
]
}
}
}
},
{
"bool": {
"must": [
{
"nested": {
"path": "parent.swagDynamicAccessRules",
"query": {
"bool": {
"must_not": [
{
"exists": {
"field": "parent.swagDynamicAccessRules.id"
}
}
]
}
}
}
},
{
"nested": {
"path": "swagDynamicAccessRules",
"query": {
"bool": {
"must_not": [
{
"exists": {
"field": "swagDynamicAccessRules.id"
}
}
]
}
}
}
}
]
}
}
]
}
}
]
}
}
],
"should": [
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"72d6226071dd404ab1f06d8b5d3d4a4a"
]
}
}
}
}
]
}
},
"boost": 1500.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"c30a42724ae94c1490305b520504ad89"
]
}
}
}
}
]
}
},
"boost": 500.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"0d4166c09d074e87bca8f27a9667258e"
]
}
}
}
}
]
}
},
"boost": 1000.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"d4236e8075c24f0aa14fbc00e5a7d2cf"
]
}
}
}
}
]
}
},
"boost": 1400.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"fc6f7b2363f34eb0ac4ce8c8bc849c80"
]
}
}
}
}
]
}
},
"boost": 2700.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"4bc0ab1b83d14c7b8a78324aa8165c19"
]
}
}
}
}
]
}
},
"boost": 2500.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"c30a42724ae94c1490305b520504ad89"
]
}
}
}
}
]
}
},
"boost": 2500.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"24bd9ef97acf49abbc2ea0668540fd93"
]
}
}
}
}
]
}
},
"boost": 900.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"e5223b47a5704804b7a91ba0cf7606b4"
]
}
}
}
}
]
}
},
"boost": 5500.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"49cd6b6ce7a44c8fa0bfbba0a58a5a52"
]
}
}
}
}
]
}
},
"boost": 5300.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"5a53c9189d664a66975560870cf888d9"
]
}
}
}
}
]
}
},
"boost": 3600.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"f1dc6f55e42245c58da422fef72b020b"
]
}
}
}
}
]
}
},
"boost": 2500.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"d9d1d3476dfe49bba602149779907f13"
]
}
}
}
}
]
}
},
"boost": 1300.0
}
},
{
"constant_score": {
"filter": {
"bool": {
"should": [
{
"nested": {
"path": "streams",
"query": {
"terms": {
"streams.id": [
"5a71cb34bc2f4e9c844f827bacfd4e5e"
]
}
}
}
}
]
}
},
"boost": 600.0
}
}
]
}
},
"sort": [
{
"customFields.2fbb5fe2e29a4d70aa5854ce7ce3e20b.custom_fields_product_pseudopurchase": {
"order": "DESC"
}
},
{
"_score": {
"order": "DESC"
}
},
{
"markAsTopseller": {
"order": "DESC"
}
},
{
"customFields.2fbb5fe2e29a4d70aa5854ce7ce3e20b.acris_search_sorting_relevance": {
"order": "DESC"
}
},
{
"id": {
"order": "ASC"
}
}
],
"aggregations": {
"total-count": {
"cardinality": {
"field": "displayGroup"
}
}
},
"from": 0,
"size": 24,
"collapse": {
"field": "displayGroup"
},
"timeout": "5s"
}
{
"took": 12,
"timed_out": false,
"_shards": {
"total": 1,
"successful": 1,
"skipped": 0,
"failed": 0
},
"hits": {
"total": {
"value": 260,
"relation": "eq"
},
"max_score": null,
"hits": [
{
"_index": "sw_product_1768215358",
"_id": "00003d29797e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194693.0,
"id": "00003d29797e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"e8309147bd02aeb905e6807d168b41f3"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00003d29797e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00003d2a267e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194387.0,
"id": "00003d2a267e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"e2854565cfae044bb67932a323344c08"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00003d2a267e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00003d2a287e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194438.0,
"id": "00003d2a287e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"20d9ca6a64e865119e475333d722f71a"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00003d2a287e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00003d2a2a7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194460.0,
"id": "00003d2a2a7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"e76fb84338411d622d06388b7af0d260"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00003d2a2a7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00003d2a2c7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194476.0,
"id": "00003d2a2c7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"d6bdcf692677d91f4a31a2937f325519"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00003d2a2c7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00004717e47e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194497.0,
"id": "00004717e47e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"4c64bbc74c1f0d15311152903ba39135"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00004717e47e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00004731de7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194686.0,
"id": "00004731de7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"81a7a82bac4cd115de916bb0c9001f96"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00004731de7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "0000476d827e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 264240.0,
"id": "0000476d827e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"326f357bb1ce67da56bb1999822cc6d3"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"0000476d827e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "000047874f7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 361782.0,
"id": "000047874f7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"caa1b9109f3224ceee535985bf0be8a9"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"000047874f7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005c53537e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194670.0,
"id": "00005c53537e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"70e8e89c3e8fc76e479548301f42cc98"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005c53537e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005c5d857e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194479.0,
"id": "00005c5d857e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"fb5a9cc3f43a304c4c99055dac14e699"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005c5d857e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005c60147e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 260838.0,
"id": "00005c60147e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"c4931cb8f5fffe400c36d473c9d48552"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005c60147e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005c6bbe7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194498.0,
"id": "00005c6bbe7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"e3e28ed1902db06ae53d32b68c1f5a85"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005c6bbe7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005c9ef77e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194637.0,
"id": "00005c9ef77e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"6304960ddf05187eec1d7b10c0634afd"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005c9ef77e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005c9f1c7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194662.0,
"id": "00005c9f1c7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"17cee53cd14cdfcf07da3c4266ff2e32"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005c9f1c7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005c9f8b7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194642.0,
"id": "00005c9f8b7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"978824521dfa800b9e515a8e9ff4d2fd"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005c9f8b7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005ca64f7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 260822.0,
"id": "00005ca64f7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"38c092ad987b8a3171b312c2729ae217"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005ca64f7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005ca6507e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194560.0,
"id": "00005ca6507e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"8cbd0697e09f2fd6a37b184bf69fdb3e"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005ca6507e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005ca6d37e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194391.0,
"id": "00005ca6d37e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"4d91083a5f4d071199bffa9bbfad6edc"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005ca6d37e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005ca6f57e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194596.0,
"id": "00005ca6f57e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"0f8416584895a7f31506aba1b10ce7ae"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005ca6f57e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005ca85f7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194449.0,
"id": "00005ca85f7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"5111f69b09f2be18f554a5fd9bc34a66"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005ca85f7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005caebc7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194411.0,
"id": "00005caebc7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"7f07e72c9182aeaee9a8d54d01baab53"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005caebc7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005cb29c7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194401.0,
"id": "00005cb29c7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"256b54d0fcfb10d80cb7bf7048341716"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005cb29c7e7e7e7e7e7e7e7e7e0003"
]
},
{
"_index": "sw_product_1768215358",
"_id": "00005cb72c7e7e7e7e7e7e7e7e7e0003",
"_score": 0.0,
"_source": {
"autoIncrement": 194684.0,
"id": "00005cb72c7e7e7e7e7e7e7e7e7e0003"
},
"fields": {
"displayGroup": [
"24489c6314845a71dc4ae76d4da5e96f"
]
},
"sort": [
-9223372036854775808,
0.0,
0,
0,
"00005cb72c7e7e7e7e7e7e7e7e7e0003"
]
}
]
},
"aggregations": {
"total-count": {
"value": 99
}
}
}
Shopware\Elasticsearch\Framework\DataAbstractionLayer\ElasticsearchEntitySearcher:search
|
| 2 |
13.66 ms |
Request:
{"index":"sw_product","track_total_hits":false,"body":{"query":{"bool":{"filter":[{"bool":{"must":[{"bool":{"must":[{"term":{"active":true}},{"range":{"visibility_a4bd6d6716d64126bd5373aabee8c9af":{"gte":30}}}]}},{"term":{"categoryTree":"00000190787e7e7e7e7e7e7e7e7e0001"}},{"exists":{"field":"displayGroup"}},{"bool":{"should":[{"bool":{"must":[{"nested":{"path":"parent.swagDynamicAccessRules","query":{"terms":{"parent.swagDynamicAccessRules.id":["092cbf7d7bb845cf871f8bc35847021a","2cf59896af66475896ec8abd03ac26b6","3858957016644de4ae48c0500bf3ccc8","3c9d7d926b6a47fe8d4ae20d0a993424","69e0e90bd44d465989887976752efdfc","e1378db7808a478f919e0d740d5d6c1a","e92b366fe0ce497b9b5e2b4c2a2cb0f6","fa9feb38521b4c508af91afafcf89eaa","26d71577e36549c88b704bb9e7f73918","28caae75a5624f0d985abd0eb32aa160","53d34850dc394bd7806d5818c3011a2d","71012c3c5bf6413d83b96241e47bd9dd"]}}}},{"nested":{"path":"swagDynamicAccessRules","query":{"bool":{"must_not":[{"exists":{"field":"swagDynamicAccessRules.id"}}]}}}}]}},{"nested":{"path":"swagDynamicAccessRules","query":{"terms":{"swagDynamicAccessRules.id":["092cbf7d7bb845cf871f8bc35847021a","2cf59896af66475896ec8abd03ac26b6","3858957016644de4ae48c0500bf3ccc8","3c9d7d926b6a47fe8d4ae20d0a993424","69e0e90bd44d465989887976752efdfc","e1378db7808a478f919e0d740d5d6c1a","e92b366fe0ce497b9b5e2b4c2a2cb0f6","fa9feb38521b4c508af91afafcf89eaa","26d71577e36549c88b704bb9e7f73918","28caae75a5624f0d985abd0eb32aa160","53d34850dc394bd7806d5818c3011a2d","71012c3c5bf6413d83b96241e47bd9dd"]}}}},{"bool":{"must":[{"nested":{"path":"parent.swagDynamicAccessRules","query":{"bool":{"must_not":[{"exists":{"field":"parent.swagDynamicAccessRules.id"}}]}}}},{"nested":{"path":"swagDynamicAccessRules","query":{"bool":{"must_not":[{"exists":{"field":"swagDynamicAccessRules.id"}}]}}}}]}}]}}]}}]}},"aggregations":{"manufacturer":{"terms":{"field":"manufacturerId","size":10000}},"price":{"stats":{"script":{"source":"double getPrice(def accessors, def doc, def decimals, def round, def multiplier) {\n for (accessor in accessors) {\n def key = accessor['key'];\n\n if (!doc.containsKey(key) || doc[key].empty) {\n continue;\n }\n\n def factor = accessor['factor'];\n def value = doc[key].value * factor;\n\n value = Math.round(value * decimals);\n value = (double) value \/ decimals;\n\n if (!round) {\n return (double) value;\n }\n\n value = Math.round(value * multiplier);\n\n value = (double) value \/ multiplier;\n\n return (double) value;\n }\n\n return 0;\n}\n\nreturn getPrice(params['accessors'], doc, params['decimals'], params['round'], params['multiplier']);\n","lang":"painless","params":{"accessors":[{"key":"cheapest_price_rule092cbf7d7bb845cf871f8bc35847021a_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule2cf59896af66475896ec8abd03ac26b6_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule3858957016644de4ae48c0500bf3ccc8_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule3c9d7d926b6a47fe8d4ae20d0a993424_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule69e0e90bd44d465989887976752efdfc_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rulee1378db7808a478f919e0d740d5d6c1a_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rulee92b366fe0ce497b9b5e2b4c2a2cb0f6_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rulefa9feb38521b4c508af91afafcf89eaa_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule26d71577e36549c88b704bb9e7f73918_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule28caae75a5624f0d985abd0eb32aa160_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule53d34850dc394bd7806d5818c3011a2d_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule71012c3c5bf6413d83b96241e47bd9dd_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_ruledefault_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1}],"decimals":100,"round":true,"multiplier":100.0}}}},"rating-exists":{"filter":{"range":{"ratingAverage":{"gte":0.0}}},"aggregations":{"rating":{"max":{"field":"ratingAverage"}}}},"shipping-free-filter":{"filter":{"term":{"shippingFree":true}},"aggregations":{"shipping-free":{"max":{"field":"shippingFree"}}}},"properties-filter":{"nested":{"path":"properties"},"aggregations":{"properties-filter":{"filter":{"terms":{"properties.groupId":["f76bac81dcfb72539908a5b297b8aeef","e1a5b583c329dd80f5f3716931aca1d2","f76bac81dcfb72539908a5b297b8aeef","e1a5b583c329dd80f5f3716931aca1d2"]}},"aggregations":{"properties":{"terms":{"field":"properties.id","size":10000}}}}}},"options-filter":{"nested":{"path":"options"},"aggregations":{"options-filter":{"filter":{"terms":{"options.groupId":["f76bac81dcfb72539908a5b297b8aeef","e1a5b583c329dd80f5f3716931aca1d2","f76bac81dcfb72539908a5b297b8aeef","e1a5b583c329dd80f5f3716931aca1d2"]}},"aggregations":{"options":{"terms":{"field":"options.id","size":10000}}}}}}},"size":0,"timeout":"5s"},"search_type":"query_then_fetch"}
POST http://localhost:9200/sw_product/_search?track_total_hits=0&search_type=query_then_fetch
Accept: application/json
Content-Type: application/json
{
"query": {
"bool": {
"filter": [
{
"bool": {
"must": [
{
"bool": {
"must": [
{
"term": {
"active": true
}
},
{
"range": {
"visibility_a4bd6d6716d64126bd5373aabee8c9af": {
"gte": 30
}
}
}
]
}
},
{
"term": {
"categoryTree": "00000190787e7e7e7e7e7e7e7e7e0001"
}
},
{
"exists": {
"field": "displayGroup"
}
},
{
"bool": {
"should": [
{
"bool": {
"must": [
{
"nested": {
"path": "parent.swagDynamicAccessRules",
"query": {
"terms": {
"parent.swagDynamicAccessRules.id": [
"092cbf7d7bb845cf871f8bc35847021a",
"2cf59896af66475896ec8abd03ac26b6",
"3858957016644de4ae48c0500bf3ccc8",
"3c9d7d926b6a47fe8d4ae20d0a993424",
"69e0e90bd44d465989887976752efdfc",
"e1378db7808a478f919e0d740d5d6c1a",
"e92b366fe0ce497b9b5e2b4c2a2cb0f6",
"fa9feb38521b4c508af91afafcf89eaa",
"26d71577e36549c88b704bb9e7f73918",
"28caae75a5624f0d985abd0eb32aa160",
"53d34850dc394bd7806d5818c3011a2d",
"71012c3c5bf6413d83b96241e47bd9dd"
]
}
}
}
},
{
"nested": {
"path": "swagDynamicAccessRules",
"query": {
"bool": {
"must_not": [
{
"exists": {
"field": "swagDynamicAccessRules.id"
}
}
]
}
}
}
}
]
}
},
{
"nested": {
"path": "swagDynamicAccessRules",
"query": {
"terms": {
"swagDynamicAccessRules.id": [
"092cbf7d7bb845cf871f8bc35847021a",
"2cf59896af66475896ec8abd03ac26b6",
"3858957016644de4ae48c0500bf3ccc8",
"3c9d7d926b6a47fe8d4ae20d0a993424",
"69e0e90bd44d465989887976752efdfc",
"e1378db7808a478f919e0d740d5d6c1a",
"e92b366fe0ce497b9b5e2b4c2a2cb0f6",
"fa9feb38521b4c508af91afafcf89eaa",
"26d71577e36549c88b704bb9e7f73918",
"28caae75a5624f0d985abd0eb32aa160",
"53d34850dc394bd7806d5818c3011a2d",
"71012c3c5bf6413d83b96241e47bd9dd"
]
}
}
}
},
{
"bool": {
"must": [
{
"nested": {
"path": "parent.swagDynamicAccessRules",
"query": {
"bool": {
"must_not": [
{
"exists": {
"field": "parent.swagDynamicAccessRules.id"
}
}
]
}
}
}
},
{
"nested": {
"path": "swagDynamicAccessRules",
"query": {
"bool": {
"must_not": [
{
"exists": {
"field": "swagDynamicAccessRules.id"
}
}
]
}
}
}
}
]
}
}
]
}
}
]
}
}
]
}
},
"aggregations": {
"manufacturer": {
"terms": {
"field": "manufacturerId",
"size": 10000
}
},
"price": {
"stats": {
"script": {
"source": "double getPrice(def accessors, def doc, def decimals, def round, def multiplier) {\n for (accessor in accessors) {\n def key = accessor['key'];\n\n if (!doc.containsKey(key) || doc[key].empty) {\n continue;\n }\n\n def factor = accessor['factor'];\n def value = doc[key].value * factor;\n\n value = Math.round(value * decimals);\n value = (double) value \/ decimals;\n\n if (!round) {\n return (double) value;\n }\n\n value = Math.round(value * multiplier);\n\n value = (double) value \/ multiplier;\n\n return (double) value;\n }\n\n return 0;\n}\n\nreturn getPrice(params['accessors'], doc, params['decimals'], params['round'], params['multiplier']);\n",
"lang": "painless",
"params": {
"accessors": [
{
"key": "cheapest_price_rule092cbf7d7bb845cf871f8bc35847021a_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule2cf59896af66475896ec8abd03ac26b6_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule3858957016644de4ae48c0500bf3ccc8_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule3c9d7d926b6a47fe8d4ae20d0a993424_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule69e0e90bd44d465989887976752efdfc_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rulee1378db7808a478f919e0d740d5d6c1a_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rulee92b366fe0ce497b9b5e2b4c2a2cb0f6_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rulefa9feb38521b4c508af91afafcf89eaa_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule26d71577e36549c88b704bb9e7f73918_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule28caae75a5624f0d985abd0eb32aa160_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule53d34850dc394bd7806d5818c3011a2d_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_rule71012c3c5bf6413d83b96241e47bd9dd_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
},
{
"key": "cheapest_price_ruledefault_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross",
"factor": 1
}
],
"decimals": 100,
"round": true,
"multiplier": 100.0
}
}
}
},
"rating-exists": {
"filter": {
"range": {
"ratingAverage": {
"gte": 0.0
}
}
},
"aggregations": {
"rating": {
"max": {
"field": "ratingAverage"
}
}
}
},
"shipping-free-filter": {
"filter": {
"term": {
"shippingFree": true
}
},
"aggregations": {
"shipping-free": {
"max": {
"field": "shippingFree"
}
}
}
},
"properties-filter": {
"nested": {
"path": "properties"
},
"aggregations": {
"properties-filter": {
"filter": {
"terms": {
"properties.groupId": [
"f76bac81dcfb72539908a5b297b8aeef",
"e1a5b583c329dd80f5f3716931aca1d2",
"f76bac81dcfb72539908a5b297b8aeef",
"e1a5b583c329dd80f5f3716931aca1d2"
]
}
},
"aggregations": {
"properties": {
"terms": {
"field": "properties.id",
"size": 10000
}
}
}
}
}
},
"options-filter": {
"nested": {
"path": "options"
},
"aggregations": {
"options-filter": {
"filter": {
"terms": {
"options.groupId": [
"f76bac81dcfb72539908a5b297b8aeef",
"e1a5b583c329dd80f5f3716931aca1d2",
"f76bac81dcfb72539908a5b297b8aeef",
"e1a5b583c329dd80f5f3716931aca1d2"
]
}
},
"aggregations": {
"options": {
"terms": {
"field": "options.id",
"size": 10000
}
}
}
}
}
}
},
"size": 0,
"timeout": "5s"
}
Shopware\Elasticsearch\Framework\DataAbstractionLayer\ElasticsearchEntityAggregator:aggregate
|