Does Elasticsearch process single-threaded bulk requests in the same order?
IMHO It will process your request in the same order per shard.
That means that if you send an index operation on doc 1 then a delete operation on doc 1, these operations will be sent in the same order to the shard.
But if you send index doc1, delete doc1, index doc2 and delete doc2, you have no guarantee (if you have multiple shards, no routing) that index doc2 will be done after index doc1 or delete doc1.
Make sense?
--
David
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
Le 26 oct. 2013 à 04:01, InquiringMind brian.from.fl@gmail.com a écrit :
Jörg,
Across nodes, there is also a kind of parallel writing, which is even harder to control, because you can have many clients sending data in parallel to the same document, and nodes can be heavily loaded and indexing progresses in different speeds. Also, if you use replica, you have to guarantee that primary index is advancing the indexing in same order as the replica indexing. Since the indexing is distributed over several nodes, there must be additional synchronization, such as vector clocks in the docs, so nodes can see the same order of the docs as the clients from which they came from. Each node has to reconstruct the correct order of the docs independent from each other.
Not exactly sure I understand the previous paragraphs, but when I created a bulk loader using the BulkRequestBuilder, it is single-threaded. And when running one instance at any given point in time to remove any change of the client getting the updates out of order, the question remains: Does Elasticsearch process single-threaded bulk requests in the same order?
I fully understand that my client needs to be single-threaded. And our data comes in such that bulk updates consists of a huge number of index and delete operations. Sometimes, their data provider creates an update by giving me a delete request followed by a create (index to ES) request. It would be Very Bad if that was processed as an index followed by the delete.
Brian
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.
For more options, visit https://groups.google.com/groups/opt_out.
--
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.
For more options, visit https://groups.google.com/groups/opt_out.