Testing refresh.interval / explanation


I'm testing the refresh.interval [2]of my ES cluster (6 nodes, ES 6.5.0).

I'm doing sync upserts into an index with refresh.interval=30s.
In a differnt app, I'm executing queries.

However I set index.interval, my second app directly see any change done my the upsert (no explicit refresh in the upsert. Using java high level rest client [1]).

My understanding of refresh.interval was that new data will not be visible until the interval is reached. How can it be that I always directly see any new/changed data?

tx for help

[1] https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/java-rest-high.html
[2] https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-update-settings.html

Bonjour Jean-Marc

What exactly are you running in your app? Is that a search or a get by id ?

I'm executing a GetRequest [1], so it's a get by id.


This is expected then. GET index/_doc/id is a realtime operation.

I just tested search, and now I see old values until refresh interval is reached.