# Is the execution order guaranteed in a single\_bulk request?

**URL:** <https://discuss.elastic.co/t/is-the-execution-order-guaranteed-in-a-single-bulk-request/100412>\
**Category:** Elasticsearch\
**Created:** [September 13, 2017, 8:28pm UTC](https://discuss.elastic.co/t/is-the-execution-order-guaranteed-in-a-single-bulk-request/100412 "2017-09-13T20:28:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![WoJ](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/woj/32/4518_2.png) [@WoJ](https://discuss.elastic.co/u/WoJ)\
**Post date:** [September 13, 2017, 8:28pm UTC](https://discuss.elastic.co/t/is-the-execution-order-guaranteed-in-a-single-bulk-request/100412/1 "2017-09-13T20:28:37Z")

</div>

Continuing the discussion from [Are bulk index operations serialized?](https://discuss.elastic.co/t/are-bulk-index-operations-serialized/83770/6):

Is this also true for several elements of one `_bulk` command? If my request (one request) has action A, then B and then C (in this order) don't I have the guarantee that the order is preserved?

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [September 13, 2017, 8:35pm UTC](https://discuss.elastic.co/t/is-the-execution-order-guaranteed-in-a-single-bulk-request/100412/2 "2017-09-13T20:35:39Z")

</div>

If they are on the same shard, then yes.  
If they aren't then we cannot guarantee that as far as I know.

---

<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:** [October 11, 2017, 8:36pm UTC](https://discuss.elastic.co/t/is-the-execution-order-guaranteed-in-a-single-bulk-request/100412/3 "2017-10-11T20:36:07Z")

</div>

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