1 |
2.33 ms |
Request:
{"index":"sw_product","search_type":"query_then_fetch","track_total_hits":true,"body":{"query":{"bool":{"filter":[{"bool":{"must":[{"bool":{"must":[{"nested":{"path":"visibilities","query":{"bool":{"must":[{"range":{"visibilities.visibility":{"gte":30}}},{"term":{"visibilities.salesChannelId":"250c23c94a704f8ba1b4819c38901688"}}]}}}},{"term":{"active":true}}]}},{"nested":{"path":"categoriesRo","query":{"term":{"categoriesRo.id":"e1994d6003c94cf280d796135b398b9f"}}}},{"bool":{"must_not":[{"bool":{"must_not":[{"exists":{"field":"displayGroup"}}]}}]}}]}}]}},"sort":[{"_script":{"type":"number","script":{"source":"def languages = params['languages'];\ndef suffix = params.containsKey('suffix') ? '.' + params['suffix'] : '';\n\nfor (int i = 0; i < languages.length; i++) {\n def field_name = params['field'] + '.' + languages[i] + suffix;\n\n if (doc[field_name].size() > 0 && doc[field_name].value != null && doc[field_name].value.toString().length() > 0) {\n def fieldValue = doc[field_name].value;\n\n return fieldValue;\n }\n}\n\nif (params['order'] == 'asc') {\n return Double.MAX_VALUE;\n}\n\nreturn Double.MIN_VALUE;\n","lang":"painless","params":{"field":"customFields","languages":["2fbb5fe2e29a4d70aa5854ce7ce3e20b"],"suffix":"custom_product_rosland_set_year","order":"desc"}},"order":"DESC"}},{"id":{"order":"ASC"}}],"aggregations":{"total-count":{"cardinality":{"field":"displayGroup"}}},"from":0,"size":36,"collapse":{"field":"displayGroup"},"timeout":"5s"}}
{
"took": 1,
"timed_out": false,
"_shards": {
"total": 3,
"successful": 3,
"skipped": 0,
"failed": 0
},
"hits": {
"total": {
"value": 23,
"relation": "eq"
},
"max_score": null,
"hits": [
{
"_index": "sw_product_1717666750",
"_id": "1870d40679f24eb2a297c029aeab16a3",
"_score": null,
"_source": {
"id": "1870d40679f24eb2a297c029aeab16a3",
"autoIncrement": 3737.0
},
"fields": {
"displayGroup": [
"31cd83e1660ad89ab89a7932fa2bbdb3"
]
},
"sort": [
5.0e-324,
"1870d40679f24eb2a297c029aeab16a3"
]
},
{
"_index": "sw_product_1717666750",
"_id": "23a3a0f4d4f445828c5883560e2031b3",
"_score": null,
"_source": {
"id": "23a3a0f4d4f445828c5883560e2031b3",
"autoIncrement": 589.0
},
"fields": {
"displayGroup": [
"c6c7c2513f44d96d1588279681dd0f6e"
]
},
"sort": [
5.0e-324,
"23a3a0f4d4f445828c5883560e2031b3"
]
},
{
"_index": "sw_product_1717666750",
"_id": "2fac48cd515e41128a979a231f2bd926",
"_score": null,
"_source": {
"id": "2fac48cd515e41128a979a231f2bd926",
"autoIncrement": 913.0
},
"fields": {
"displayGroup": [
"b54be5565a670de434e590714d03d7ad"
]
},
"sort": [
5.0e-324,
"2fac48cd515e41128a979a231f2bd926"
]
},
{
"_index": "sw_product_1717666750",
"_id": "479337ca764c42c7b16521d3f04ae9d6",
"_score": null,
"_source": {
"id": "479337ca764c42c7b16521d3f04ae9d6",
"autoIncrement": 3739.0
},
"fields": {
"displayGroup": [
"2c70ca3b1377a9754eacbd313bbed655"
]
},
"sort": [
5.0e-324,
"479337ca764c42c7b16521d3f04ae9d6"
]
},
{
"_index": "sw_product_1717666750",
"_id": "4c591b4dbd694c30a305b8f96b48f24d",
"_score": null,
"_source": {
"id": "4c591b4dbd694c30a305b8f96b48f24d",
"autoIncrement": 2959.0
},
"fields": {
"displayGroup": [
"c90aaf002bdd69a4428f9d8c71a5d19f"
]
},
"sort": [
5.0e-324,
"4c591b4dbd694c30a305b8f96b48f24d"
]
},
{
"_index": "sw_product_1717666750",
"_id": "5b1497c373ef42048d5917f8d813f996",
"_score": null,
"_source": {
"id": "5b1497c373ef42048d5917f8d813f996",
"autoIncrement": 3457.0
},
"fields": {
"displayGroup": [
"c7249f4bcfe5e052d723db23f8701a87"
]
},
"sort": [
5.0e-324,
"5b1497c373ef42048d5917f8d813f996"
]
},
{
"_index": "sw_product_1717666750",
"_id": "784d9356b9f64fe29513904443a3d6c5",
"_score": null,
"_source": {
"id": "784d9356b9f64fe29513904443a3d6c5",
"autoIncrement": 4261.0
},
"fields": {
"displayGroup": [
"0ab871956e4400cb751c4e0333a39eb0"
]
},
"sort": [
5.0e-324,
"784d9356b9f64fe29513904443a3d6c5"
]
},
{
"_index": "sw_product_1717666750",
"_id": "7ce539f441f44d4591765f381e6337bb",
"_score": null,
"_source": {
"id": "7ce539f441f44d4591765f381e6337bb",
"autoIncrement": 3751.0
},
"fields": {
"displayGroup": [
"3cc44f69991736cba2d71835d43d9a6c"
]
},
"sort": [
5.0e-324,
"7ce539f441f44d4591765f381e6337bb"
]
},
{
"_index": "sw_product_1717666750",
"_id": "80d3480370ee4c22b19ef467f2440204",
"_score": null,
"_source": {
"id": "80d3480370ee4c22b19ef467f2440204",
"autoIncrement": 3756.0
},
"fields": {
"displayGroup": [
"1f57dc2a5b0d6031055bcb93ca89ad4d"
]
},
"sort": [
5.0e-324,
"80d3480370ee4c22b19ef467f2440204"
]
},
{
"_index": "sw_product_1717666750",
"_id": "853803747d494e1a870bb4bd368c0950",
"_score": null,
"_source": {
"id": "853803747d494e1a870bb4bd368c0950",
"autoIncrement": 2961.0
},
"fields": {
"displayGroup": [
"8d7fc0942a9d05fa97ff85aa0dcc6811"
]
},
"sort": [
5.0e-324,
"853803747d494e1a870bb4bd368c0950"
]
},
{
"_index": "sw_product_1717666750",
"_id": "97e5745b0a31413f939f0d320b7cbf4d",
"_score": null,
"_source": {
"id": "97e5745b0a31413f939f0d320b7cbf4d",
"autoIncrement": 2958.0
},
"fields": {
"displayGroup": [
"4b22d7e6181995be95c37b9b01d26e99"
]
},
"sort": [
5.0e-324,
"97e5745b0a31413f939f0d320b7cbf4d"
]
},
{
"_index": "sw_product_1717666750",
"_id": "a1432de11d644e6fa65bc0016d5329b3",
"_score": null,
"_source": {
"id": "a1432de11d644e6fa65bc0016d5329b3",
"autoIncrement": 590.0
},
"fields": {
"displayGroup": [
"659adc4fc5c867d51eb80d3f317f3cf8"
]
},
"sort": [
5.0e-324,
"a1432de11d644e6fa65bc0016d5329b3"
]
},
{
"_index": "sw_product_1717666750",
"_id": "a62199fd67f84db39de633b74dc12e8d",
"_score": null,
"_source": {
"id": "a62199fd67f84db39de633b74dc12e8d",
"autoIncrement": 3736.0
},
"fields": {
"displayGroup": [
"36cd608f9ab7d2a9c95aa2a468f81a34"
]
},
"sort": [
5.0e-324,
"a62199fd67f84db39de633b74dc12e8d"
]
},
{
"_index": "sw_product_1717666750",
"_id": "a7d05c8dff444971b2a67e715a100df2",
"_score": null,
"_source": {
"id": "a7d05c8dff444971b2a67e715a100df2",
"autoIncrement": 591.0
},
"fields": {
"displayGroup": [
"7713aa057d2df8f6b7774da72ef2034e"
]
},
"sort": [
5.0e-324,
"a7d05c8dff444971b2a67e715a100df2"
]
},
{
"_index": "sw_product_1717666750",
"_id": "b1bb148e905741129d2bd217131de401",
"_score": null,
"_source": {
"id": "b1bb148e905741129d2bd217131de401",
"autoIncrement": 2960.0
},
"fields": {
"displayGroup": [
"2daeec48f42c3ff8d72e76677b84616b"
]
},
"sort": [
5.0e-324,
"b1bb148e905741129d2bd217131de401"
]
},
{
"_index": "sw_product_1717666750",
"_id": "c09f3a0185c9411eb7224fcf72c6e7d4",
"_score": null,
"_source": {
"id": "c09f3a0185c9411eb7224fcf72c6e7d4",
"autoIncrement": 3754.0
},
"fields": {
"displayGroup": [
"da75c439b488b3f9f1e76909f29d965b"
]
},
"sort": [
5.0e-324,
"c09f3a0185c9411eb7224fcf72c6e7d4"
]
},
{
"_index": "sw_product_1717666750",
"_id": "d82cf8e7396d47f5be56c100071dc68b",
"_score": null,
"_source": {
"id": "d82cf8e7396d47f5be56c100071dc68b",
"autoIncrement": 3755.0
},
"fields": {
"displayGroup": [
"4174f85e0c2bf60662bc229bfc81ee7a"
]
},
"sort": [
5.0e-324,
"d82cf8e7396d47f5be56c100071dc68b"
]
},
{
"_index": "sw_product_1717666750",
"_id": "e491ff5f49e74a7ca4fbbf2b84a80659",
"_score": null,
"_source": {
"id": "e491ff5f49e74a7ca4fbbf2b84a80659",
"autoIncrement": 3515.0
},
"fields": {
"displayGroup": [
"ab1164d098ae60ca897d8e0c0edc43ce"
]
},
"sort": [
5.0e-324,
"e491ff5f49e74a7ca4fbbf2b84a80659"
]
},
{
"_index": "sw_product_1717666750",
"_id": "ec9780631346481890b374d95eda9a75",
"_score": null,
"_source": {
"id": "ec9780631346481890b374d95eda9a75",
"autoIncrement": 4316.0
},
"fields": {
"displayGroup": [
"68af31e1f034ffe44719209974c619bd"
]
},
"sort": [
5.0e-324,
"ec9780631346481890b374d95eda9a75"
]
},
{
"_index": "sw_product_1717666750",
"_id": "efdce87adf1a44cfbe8c62150382d28f",
"_score": null,
"_source": {
"id": "efdce87adf1a44cfbe8c62150382d28f",
"autoIncrement": 3287.0
},
"fields": {
"displayGroup": [
"1554f72b9a6396f20e74be344c252447"
]
},
"sort": [
5.0e-324,
"efdce87adf1a44cfbe8c62150382d28f"
]
},
{
"_index": "sw_product_1717666750",
"_id": "f1bc1ed89dda471da8912fdb29ccc6c3",
"_score": null,
"_source": {
"id": "f1bc1ed89dda471da8912fdb29ccc6c3",
"autoIncrement": 3738.0
},
"fields": {
"displayGroup": [
"b4c63b29ab714d86cf7238fef1859c43"
]
},
"sort": [
5.0e-324,
"f1bc1ed89dda471da8912fdb29ccc6c3"
]
},
{
"_index": "sw_product_1717666750",
"_id": "fd18ddd299fc4eb19628f8050cb19d39",
"_score": null,
"_source": {
"id": "fd18ddd299fc4eb19628f8050cb19d39",
"autoIncrement": 3713.0
},
"fields": {
"displayGroup": [
"de0c56d9d05d56c7ab3bde95b0851357"
]
},
"sort": [
5.0e-324,
"fd18ddd299fc4eb19628f8050cb19d39"
]
},
{
"_index": "sw_product_1717666750",
"_id": "ff7715175dc64f989b8b696364a5ba4e",
"_score": null,
"_source": {
"id": "ff7715175dc64f989b8b696364a5ba4e",
"autoIncrement": 3707.0
},
"fields": {
"displayGroup": [
"02cd3885fb98f08f82c7c29faf161fce"
]
},
"sort": [
5.0e-324,
"ff7715175dc64f989b8b696364a5ba4e"
]
}
]
},
"aggregations": {
"total-count": {
"value": 23
}
}
}
Shopware\Elasticsearch\Framework\DataAbstractionLayer\ElasticsearchEntitySearcher:search
|
2 |
1.05 ms |
Request:
{"index":"sw_product","track_total_hits":false,"body":{"query":{"bool":{"filter":[{"bool":{"must":[{"bool":{"must":[{"nested":{"path":"visibilities","query":{"bool":{"must":[{"range":{"visibilities.visibility":{"gte":30}}},{"term":{"visibilities.salesChannelId":"250c23c94a704f8ba1b4819c38901688"}}]}}}},{"term":{"active":true}}]}},{"nested":{"path":"categoriesRo","query":{"term":{"categoriesRo.id":"e1994d6003c94cf280d796135b398b9f"}}}},{"bool":{"must_not":[{"bool":{"must_not":[{"exists":{"field":"displayGroup"}}]}}]}}]}}]}},"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_rule64bf19224e314563aba24460dda765f8_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule89d3fe06bd7c478194fe9179a9602df5_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_ruled980a6dfc7774cd192e0b1a183764274_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule01961afbc995737796b164a7b5355b5d_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule01961afbca2673cf9fb2d67da0cd8a62_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule0197e9e4d10e7293b705c1d0eee95b29_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule0197e9e4d446718a91aafc7b03ab341a_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rule6235b68395cd475f90278d41d7b1b36c_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_ruleac5af03b5965434681e7c4cb42720d2b_currencyb7d2554b0ce847cd82f3ac9bd1c0dfca_gross","factor":1},{"key":"cheapest_price_rulecc1de6f5416545d3a68a00f78e8f20f3_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":{"nested":{"path":"properties"},"aggregations":{"properties":{"terms":{"field":"properties.id","size":10000}}}},"options":{"nested":{"path":"options"},"aggregations":{"options":{"terms":{"field":"options.id","size":10000}}}}},"size":0,"timeout":"5s"},"search_type":"query_then_fetch"}
{
"took": 0,
"timed_out": false,
"_shards": {
"total": 3,
"successful": 3,
"skipped": 0,
"failed": 0
},
"hits": {
"max_score": null,
"hits": []
},
"aggregations": {
"shipping-free-filter": {
"doc_count": 0,
"shipping-free": {
"value": null
}
},
"rating-exists": {
"doc_count": 23,
"rating": {
"value": 0.0
}
},
"price": {
"count": 23,
"min": 4.0,
"max": 4723.95,
"avg": 1158.8634782608697,
"sum": 26653.86
},
"options": {
"doc_count": 0,
"options": {
"doc_count_error_upper_bound": 0,
"sum_other_doc_count": 0,
"buckets": []
}
},
"properties": {
"doc_count": 210,
"properties": {
"doc_count_error_upper_bound": 0,
"sum_other_doc_count": 0,
"buckets": [
{
"key": "45018ee86cc84c47b8d18583215e11fb",
"doc_count": 23
},
{
"key": "70d623b6cfc0418c841d5717feb365d3",
"doc_count": 16
},
{
"key": "b1db92116aaf46d5a308b7ad5f134d9d",
"doc_count": 13
},
{
"key": "10d8bb1a9bd44f14859020697968d3c1",
"doc_count": 12
},
{
"key": "423ac04ee24a4f1088823bea1a1c3eff",
"doc_count": 12
},
{
"key": "4aa97bbcbc514f88845b8df088fbcebd",
"doc_count": 12
},
{
"key": "8483761088294ffa80403e23c4ad284f",
"doc_count": 11
},
{
"key": "96727510cafc4fb298b1c730d3adf286",
"doc_count": 11
},
{
"key": "d0c8f4e1d94045cca43e4f8b05422e8f",
"doc_count": 11
},
{
"key": "b040cc0159d544d7b4d29a65b03e143c",
"doc_count": 10
},
{
"key": "d7e6d5a8a0634ae5bd955e31cc02c61f",
"doc_count": 10
},
{
"key": "085ee8fe54d14e1b9f0eed4a310216ec",
"doc_count": 6
},
{
"key": "256aa072d598469cbe2a99d63859b36e",
"doc_count": 6
},
{
"key": "e856ca41a5c741258e8e140713642604",
"doc_count": 6
},
{
"key": "f066866f14314e959fbb38aeaac3a6a6",
"doc_count": 6
},
{
"key": "f3addfa0aa8f492b93ef4d41f76ff1fd",
"doc_count": 6
},
{
"key": "13b15b96fee74c2fb4fe836186da4cae",
"doc_count": 5
},
{
"key": "8b943009f9534110a0f4810bee03fd08",
"doc_count": 4
},
{
"key": "f3e11eb6dee04d859b36b3d99864b3f5",
"doc_count": 4
},
{
"key": "24e7f5a766024bb1b57a7ed264c1c3a9",
"doc_count": 3
},
{
"key": "500c2a4c89814a53aa63d92e5c27005c",
"doc_count": 3
},
{
"key": "67888f37f0274fd2acf261ee4dff97df",
"doc_count": 3
},
{
"key": "6b093f1a394549008c2ceea922a3450d",
"doc_count": 3
},
{
"key": "7f609e84e0434abe89672b52aca742a6",
"doc_count": 3
},
{
"key": "c8f2244aab7c462680417a11a92b4d56",
"doc_count": 3
},
{
"key": "90b151c38cf94ac9b3eae6911ba4a16d",
"doc_count": 2
},
{
"key": "c00d09ec51844aefa2781fcc00839644",
"doc_count": 2
},
{
"key": "051d25daf1ca46b0b5b363c0b850ff90",
"doc_count": 1
},
{
"key": "46563eb1f61e4acfa405e5a62c4fb388",
"doc_count": 1
},
{
"key": "5209fed2a5cf4827be55eb9c95783cb1",
"doc_count": 1
},
{
"key": "b449e94d970e42228521a3959685d688",
"doc_count": 1
}
]
}
},
"manufacturer": {
"doc_count_error_upper_bound": 0,
"sum_other_doc_count": 0,
"buckets": [
{
"key": "3f99b6c9b12947e3aa2fc9d42bb93a1d",
"doc_count": 12
},
{
"key": "9e7272c1fdea44728ce76a9a0f79f82e",
"doc_count": 11
}
]
}
}
}
Shopware\Elasticsearch\Framework\DataAbstractionLayer\ElasticsearchEntityAggregator:aggregate
|