# Index time for new documents

**URL:** <https://discuss.elastic.co/t/index-time-for-new-documents/13376>\
**Category:** Elasticsearch\
**Created:** [August 28, 2013, 7:08pm UTC](https://discuss.elastic.co/t/index-time-for-new-documents/13376 "2013-08-28T19:08:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Phil\_Greenberg](https://avatars.discourse-cdn.com/v4/letter/p/2acd7d/32.png) [@Phil\_Greenberg](https://discuss.elastic.co/u/Phil_Greenberg)\
**Post date:** [August 28, 2013, 7:08pm UTC](https://discuss.elastic.co/t/index-time-for-new-documents/13376/1 "2013-08-28T19:08:21Z")

</div>

I ran a stress test on a local ES DB, to see how long after adding a  
document I could successfully search for it.

I noticed that in many cases, it takes about 1 second. My suspicion is  
that the indexer runs about every 1 seconds, is that the case? Is there a  
variable which can be set to change this if needed?

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![polyfractal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/polyfractal/32/48162_2.png) [@polyfractal](https://discuss.elastic.co/u/polyfractal)\
**Post date:** [August 28, 2013, 10:31pm UTC](https://discuss.elastic.co/t/index-time-for-new-documents/13376/2 "2013-08-28T22:31:25Z")

</div>

Yep, Elasticsearch runs a "refresh" once per second by default. This  
refresh makes new documents searchable.

You can dynamically change how often the refresh is executed by modifying  
the `refresh_interval` setting using the Update Settings API[http://www.elasticsearch.org/guide/reference/api/admin-indices-update-settings/](http://www.elasticsearch.org/guide/reference/api/admin-indices-update-settings/),  
and can manually call a refresh with the Refresh API.[http://www.elasticsearch.org/guide/reference/api/admin-indices-refresh/](http://www.elasticsearch.org/guide/reference/api/admin-indices-refresh/)

-Zach

On Wednesday, August 28, 2013 3:08:21 PM UTC-4, Phil Greenberg wrote:

> I ran a stress test on a local ES DB, to see how long after adding a  
> document I could successfully search for it.
> 
> I noticed that in many cases, it takes about 1 second. My suspicion is  
> that the indexer runs about every 1 seconds, is that the case? Is there a  
> variable which can be set to change this if needed?

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Phil\_Greenberg](https://avatars.discourse-cdn.com/v4/letter/p/2acd7d/32.png) [@Phil\_Greenberg](https://discuss.elastic.co/u/Phil_Greenberg)\
**Post date:** [August 29, 2013, 4:37pm UTC](https://discuss.elastic.co/t/index-time-for-new-documents/13376/3 "2013-08-29T16:37:51Z")

</div>

Awesome, thanks for the help!

On Wednesday, August 28, 2013 12:08:21 PM UTC-7, Phil Greenberg wrote:

> I ran a stress test on a local ES DB, to see how long after adding a  
> document I could successfully search for it.
> 
> I noticed that in many cases, it takes about 1 second. My suspicion is  
> that the indexer runs about every 1 seconds, is that the case? Is there a  
> variable which can be set to change this if needed?

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<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:** [July 6, 2017, 2:18am UTC](https://discuss.elastic.co/t/index-time-for-new-documents/13376/4 "2017-07-06T02:18:57Z")

</div>


