# Typical latency of bulk insert

**URL:** <https://discuss.elastic.co/t/typical-latency-of-bulk-insert/83108>\
**Category:** Elasticsearch\
**Created:** [April 20, 2017, 7:23pm UTC](https://discuss.elastic.co/t/typical-latency-of-bulk-insert/83108 "2017-04-20T19:23:20Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mister\_L](https://avatars.discourse-cdn.com/v4/letter/m/c68b51/32.png) [@Mister\_L](https://discuss.elastic.co/u/Mister_L)\
**Post date:** [April 20, 2017, 7:23pm UTC](https://discuss.elastic.co/t/typical-latency-of-bulk-insert/83108/1 "2017-04-20T19:23:20Z")

</div>

Hi,

This question may not have sufficient data to provide an accurate answer, but I'll settle for an approximate one. I'm planning to perform a lot of bulk inserts with node js elasticsearch, in chunks of 5MB. The ES is installed on a quad core, 8GB memory machine, and the script that runs the bulk inserts is located on another machine, but in the same VPN. I'm wondering what is the latency that I'm supposed to expect from each insert (50ms, 500ms, 50s?), since this value is important to ensure the proper flow of my script.

Thanks.

---

<div class="post-metadata">

**Author:** ![KodrAus](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kodraus/32/22798_2.png) [@KodrAus](https://discuss.elastic.co/u/KodrAus)\
**Post date:** [April 21, 2017, 12:54am UTC](https://discuss.elastic.co/t/typical-latency-of-bulk-insert/83108/2 "2017-04-21T00:54:03Z")

</div>

It is one of those _how long is a piece of string_ questions. The best way to answer your question would probably be to measure it in your environment and see. Are you talking about latency between submitting the bulk request and receiving confirmation, or submitting the bulk request and the results being observable to queries?

---

<div class="post-metadata">

**Author:** ![Mister\_L](https://avatars.discourse-cdn.com/v4/letter/m/c68b51/32.png) [@Mister\_L](https://discuss.elastic.co/u/Mister_L)\
**Post date:** [April 21, 2017, 6:20am UTC](https://discuss.elastic.co/t/typical-latency-of-bulk-insert/83108/3 "2017-04-21T06:20:40Z")

</div>

I'm talking about latency between submitting the bulk request and receiving confirmation

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [April 21, 2017, 6:42am UTC](https://discuss.elastic.co/t/typical-latency-of-bulk-insert/83108/4 "2017-04-21T06:42:12Z")

</div>

If you benchmark with different bulk sizes and varying number of concurrent writers, you will be able to determine the throughput your cluster can handle. Depending on how much data you send to Elasticsearch in parallel, the latency of each bulk request will vary as the amount it takes to process this volume depends on the maximum throughput the cluster can sustain. Smaller bulk requests and fewer writers will most likely result in lower latencies, but you may see the same total throughput with larger requests and longer latencies.

---

<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 19, 2017, 6:52am UTC](https://discuss.elastic.co/t/typical-latency-of-bulk-insert/83108/5 "2017-05-19T06:52:18Z")

</div>

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