Index warm up to speed up query time

Hi,
I'd like to know whether there is a way that I can perform some kind of warm-up to speed up query process. Say if I have 50,000 documents in an index, and need to warm up 500 query strings. What I found was if I run es query for every 500 query string , it will boost query speed if I query the same query string again. So users won't experience delay. However, after certain time, say 24 hours, it slows down again when query the same query string. I thought the query result somehow will be cached in memory or hard drive for next same query search. But it doesn't seem like this way. I am new to this field, so any idea about this question would be really appreciated.

Thanks so much

There is a cache, it's an LRU eviction.
https://www.elastic.co/guide/en/elasticsearch/reference/5.1/query-cache.html might be useful.

Thanks for the info.
Additionally, is there any way I can set up cache in hard ware level?

Thanks

Dunno, check your server manuals?

More specifically, the es query I use is full-text query, using match. I assume I can also use LRU eviction, as you mentioned?

In addition, how long does this cache last, e.g. 1 or 2 days? Or there is no setting regarding to how to control how long the search cache last?

Sorry for the typo. I meant can I save cache in hard drive* ? Thanks

Caches like this one are stored in heap.
There is no ability to control how to age them out/

Thanks.

  1. To clarify, I am not so sure about the following statement in the official document. Would you mind to explain? Does this mean if my es query only involves full text search, using match, without bool filter (e.g. should, must ..etc.) will NOT work in cache?

"The query cache only caches queries which are being used in a filter context."

  1. Also, any suggestion of how to test efficiently if cache really works?

Thanks

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