Elasticsearch returning empty result

I am using a 2.3 version elastic search.
Sometimes, elastic search returns an empty result even when data is present.
It usually gives the right data on retry. But why does it return empty in the first try.
Any known issues or pointers which can help me here.

Could you share the full response when both cases are happening?

BTW 2.3 is super old and not maintained anymore.

I am using the Jest client for querying the elastic search. The Jest client returns the object for search result which gives me isSucceeded as TRUE. And the data is not present in the search result.
The same query is fired after 10secinds and I get the expected data.
The query that was fired was similar to
{
"query": {
"bool": {
"must": [{
"match": {
"ProgramId": "SampleProgramId"
}
}, {
"match": {
"TraderId": "SampleTrader"
}
}, {
"match": {
"CustomerId": "SampleCustomer"
}
}, {
"match": {
"TradeStatus": "SampleStatus"
}
}],
"filter": [{
"range": {
"TradeStartDate": {
"gte": 123456,
"lte": 654321
}
}
}]
}
}
}

But is there a way to debug and print what Jest received as the http response and share it please?

This doesn't happen often. It happened twice in past 20 days. I have anyways put the logs, but not sure about the next occurrence

I just wanted to know if some shards were failing during that specific search. This is part of the response.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.