Search query not doing fetches

Hi guys,

I'm checking through the field search.fetch_total of the _nodes/stats API how many fetches a search query is triggering, but it's not triggering any fetch.

I tried to add different filters with random values to make sure that they are not cached, also cleaned the cache just in case, but still the same.

Also, even if the query is being cached, I thought that the fetch phase is necessary anyway.

Why is that happening? Is it related to some different kind of caching (OS cache, etc)?

Thanks in advance.

I think I found out that File System Cache is not related.

Tried to restart the operating system, which causes the file system cache to be trashed; but even after that it has the same behavior (no fetches).

That is how many times call fetch in fetch phase.
You should read https://www.elastic.co/guide/en/elasticsearch/guide/2.x/_fetch_phase.html .
And https://www.elastic.co/guide/en/elasticsearch/guide/2.x/distributed-search.html .

And Es cache document is https://www.elastic.co/guide/en/elasticsearch/reference/5.6/shard-request-cache.html

Thanks for the answer.

In the link about Shard request cache it says:

By default, the requests cache will only cache the results of search requests where size=0, so it will not cache hits, but it will cache hits.total, aggregations, and suggestions.

In my case, the size of the query is more than 0, so I guess the request is not being cached. Still wondering why any fetches are being triggered.

Any thoughts?

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