On various Elasticsearch deployments I am finding that the first time I create a document in a new index each day (or at least in a long period of time) the response time is much higher. In these cases the total response time (measured from the client) is often 5-10 seconds, compared to a few 100s of milliseconds when creating a document in an existing index.
If I consecutively create documents in multiple new indexes, I only see increased response times in the first case. If my first document creation of the day is to an existing index it appears normal, but when I first create a new index I still see the increased response time.
I am using AWS's ElasticSearch service with a mix of "t2.small.elasticsearch" and "t3.small.elasticsearch" instances, but the CPU load is consistently low so I would not expect any increased latency due to that. I am seeing this behaviour even on newly-created instances, with very low document and index counts, albeit to a lesser degree.
Is this expected behaviour? If so, what causes it to only occur once a day?