Can someone help me craft an Elasticsearch query that is likely to time out on a few thousand records/documents? I would like to see what is actually returned when an aggregation request times out. Is this documented anywhere?
My attempt so far:
POST /myindex/_search?size=0
{
"aggs" : {
"total-cost" : {
"sum" : {
"field" : "cost",
"missing": 1
}
}
}
}
The reason for this question is sometimes in production I get a response that's missing the "total-cost" aggregation. I have a hunch it might be due to timeouts. That's why I want to see what is returned exactly when a request times out.
I've also looked at how to set the request timeout in the Kibana console, and apparently there is no way to do this.
NB. I am talking about search timeouts, not connection timeouts.