Elasticsearch slow at the beginning of searching , and segment memory is 0

When I was testing the performance on 10 millions of docs, I found the performance was really bad at the beginning (~20s) but fast after thousands of search.

Then I use _cat/segments?v=true to check my segments and the memory they cost, and found that "size.memory" are all 0! I think this is the reason that make my query so slow.

And I wonder how to set the configration to put the segments all in memory.

That's pretty typical, as Elasticsearch (and the OS) needs to know what is being requested to then start to cache things for faster future response/

I don't believe there is a way to force this.

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