# Does all indexation requests pass by the master node?

**URL:** <https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006>\
**Category:** Elasticsearch\
**Created:** [June 28, 2019, 9:36am UTC](https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006 "2019-06-28T09:36:58Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Askia\_Mohamed\_Kadri](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/askia_mohamed_kadri/32/134665_2.png) [@Askia\_Mohamed\_Kadri](https://discuss.elastic.co/u/Askia_Mohamed_Kadri)\
**Post date:** [June 28, 2019, 9:36am UTC](https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006/1 "2019-06-28T09:36:58Z")

</div>

Hi!  
I have a question here. When a node receives an indexation query and doesn't have the primary shard. What is it's behavior?  
Does it transfert the request to the master node that ships it to the dedicated node to answer it?  
Or does it already know where the primary shard is and directly transfert it to the dedicated node that has the primary shard?

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 28, 2019, 11:00am UTC](https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006/2 "2019-06-28T11:00:05Z")

</div>

It goes to the node which is holding the primary.

---

<div class="post-metadata">

**Author:** ![Askia\_Mohamed\_Kadri](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/askia_mohamed_kadri/32/134665_2.png) [@Askia\_Mohamed\_Kadri](https://discuss.elastic.co/u/Askia_Mohamed_Kadri)\
**Post date:** [June 28, 2019, 2:24pm UTC](https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006/3 "2019-06-28T14:24:49Z")

</div>

Thanks @dadoonet for your reply. Then I have another question...  
Lets say I have 5 nodes on different servers on which my app can send requests. I have 4 requests at the same time that updates a document and all 4 nodes ships the request to the 5th one.  
How is that handled. There is for sure an order based on timestamp (in micro or nano seconds for example).  
How does Elasticsearch handles document versioning and timestamping in case of multiple indexation on the same document of a shard?

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 28, 2019, 2:47pm UTC](https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006/4 "2019-06-28T14:47:26Z")

</div>

The last request will most likely overwrite all the previous ones.

But you might want to read [https://www.elastic.co/blog/elasticsearch-versioning-support](https://www.elastic.co/blog/elasticsearch-versioning-support) although it's a bit old.

---

<div class="post-metadata">

**Author:** ![Askia\_Mohamed\_Kadri](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/askia_mohamed_kadri/32/134665_2.png) [@Askia\_Mohamed\_Kadri](https://discuss.elastic.co/u/Askia_Mohamed_Kadri)\
**Post date:** [June 28, 2019, 2:53pm UTC](https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006/5 "2019-06-28T14:53:35Z")

</div>

Yes, that's what I'm suppose to see happening considering that all the updates from the 3 other nodes have been made before and so my document version would have been increased 4 times right?

Thanks for the blog, I'll check it.

---

<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 26, 2019, 2:53pm UTC](https://discuss.elastic.co/t/does-all-indexation-requests-pass-by-the-master-node/188006/6 "2019-07-26T14:53:36Z")

</div>

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