-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Description
Hello,
The refresh_interval documentation have changed in 7.0+, making it's new behavior unclear.
Describe the Issue:
By default, Elasticsearch runs this operation every second, but only on indices that have received one search request or more in the last 30 seconds. This is the optimal configuration if you have no or very little search traffic (e.g. less than one search request every 5 minutes) and want to optimize for indexing speed.
On the other hand, if your index experiences regular search requests, this default behavior means that Elasticsearch will refresh your index every 1 second. If you can afford to increase the amount of time between when a document gets indexed and when it becomes visible, increasing the index.refresh_interval to a larger value, e.g. 30s, might help improve indexing speed.
If I modify the refresh_interval setting, the documentation isn't clear if the behavior " but only on indices that have received one search request or more in the last 30 seconds." is kept or not.
Example :
If I set refresh_interval to 5s
If I'll have a refresh:
-
every 5 seconds, but only on indices that have received one search request or more in the last 30 seconds.
-
every 5 seconds contact, no matter what
From my testing, the behavior (only on indices that have received one search request or more in the last 30 seconds) "break" and isn't applied anymore if I modify the refresh_interval.
I think documentation should specify that