# Refresh strategy for real-time

**URL:** <https://discuss.elastic.co/t/refresh-strategy-for-real-time/175219>\
**Category:** Elasticsearch\
**Created:** [April 3, 2019, 1:58pm UTC](https://discuss.elastic.co/t/refresh-strategy-for-real-time/175219 "2019-04-03T13:58:59Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bviz](https://avatars.discourse-cdn.com/v4/letter/b/5e9695/32.png) [@bviz](https://discuss.elastic.co/u/bviz)\
**Post date:** [April 3, 2019, 1:58pm UTC](https://discuss.elastic.co/t/refresh-strategy-for-real-time/175219/1 "2019-04-03T13:58:59Z")

</div>

Hello.

We use Elastic to index about 260M documents, about 150GB in size. We need the indexed data to be available in real-time (we query the data right after we index it), so we call a refresh after indexing documents, which turned to be, expectedly, to be a performance problem for our cluster when there is high load.

We tried to reduce the need of real-time data in elastic as much as we could, but we have reached some barriers that we couldn't solve without doing manual refreshes after indexing.

I am wondering if there are any best practices around real time and refreshes that we could implement to overcome the real-time limitation, and have the data available right after index time.

I've read about the wait\_for refresh configuration, but I'm affraid that at high load, it will create alot of refresh listeners in elastic and the queues will be full.

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [April 3, 2019, 4:15pm UTC](https://discuss.elastic.co/t/refresh-strategy-for-real-time/175219/2 "2019-04-03T16:15:24Z")

</div>

> [@bviz](#):
>
> I've read about the wait\_for refresh configuration, but I'm affraid that at high load, it will create alot of refresh listeners in elastic and the queues will be full.

Do you mean you've tried `?refresh=wait_for` and found it to cause problems? I ask because if you create too many refresh listeners then this triggers a refresh, which sounds like it might be what you are wanting.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [May 1, 2019, 4:16pm UTC](https://discuss.elastic.co/t/refresh-strategy-for-real-time/175219/3 "2019-05-01T16:16:12Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
