Are you indexing documents into the indices that you are searching? Do you have index.refresh_interval set on all the indices that you are searching? If the answers are "yes" and "no" then Elasticsearch stops doing background refreshes to improve indexing performance, but the first search after a gap will need to refresh first, and this can take some time. You can disable this optimisation by setting index.refresh_interval to an appropriate value on these 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.