We have a small cluster and we would like to known if the time for a search query, without the cache, is correct. You see, we have 1TB, more than 100 Million documents, and the first search takes about 20-30 seconds, but if we call it again it only needs a second.
We are using POST /_cache/clear, but the search time stills a second. Maybe we are using it wrong, the cache is not erase, or our problem is cause by another thing.
The Elastic version is 5.5.0
It might be that the file system cache is kicking in here (just an assumption) and not any Elasticsearch cache.
You could clear out that cache (there is a file in the proc-fs you can append a value to do this, I think it is name drop_caches, on top of my head) and see if that was the reason for your performance boost.
Without the file system cache we made it slower, but not as much as other times. We assume that during the first search, is when the cache is created, and it takes several seconds or even minutes to finish. So if we erase it, It should cost as much as before, isn't it?
To give some context, we refer to first search to the first queries after long periods of time without receiving queries, or after opening or closing several indices.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.