Hi,
I'm running a very simple query which uses range on @timestmap field (Type: date).
From some reason I see using Profile API than it is rewritten to multiple TermQuery on this field.
I was wondering why is that happening and is it suppose to be faster than range query?
Query
{
"profile": "true",
"query": {
"filtered": {
"query": {
"query_string": {
"analyze_wildcard": true,
"query": "*"
}
},
"filter": {
"bool": {
"must": [
{
"range": {
"@timestamp": {
"gte": "1468829704652",
"lte": "1469434504652"
}
}
}
],
"must_not": []
}
}
}
},
"size": 500,
"fields": [
"*",
"_source"
],
"script_fields": {}
}
Query API shows many of this:
{
"query_type": "BooleanQuery",
"lucene": "@timestamp:0 \u0000\u0000\nX0o @timestamp:0 \u0000\u0000\nX0p @timestamp:0 \u0000\u0000\nX0q @timestamp:0 \u0000\u0000\nX0r @timestamp:0 \u0000\u0000\nX0s @timestamp:0 \u0000\u0000\nX0t @timestamp:0 \u0000\u0000\nX3,",
"time": "0.5339960000ms",
"breakdown": {
"score": 0,
"create_weight": 42867,
"build_scorer": 33021,
"match": 0,
"advance": 0,
"next_doc": 349037
},
Any idea?