Multi-threaded asynchronous concurrency control inside ES

Source: Internet
Author: User

Version Meta data
(1) When creating a document for the first time, its _version version number is 1, and each time the document is modified or deleted, it will automatically add 1 to this _version version number.
(2) When deleting a document, it is not immediately physically deleted, some of its version number and other information remains. Delete a document first, in the re-creation of this document, in fact, will be on the delete version base, and then add the version number 1
———————————————————————————————————————————————————————————————
Es in the background, many similar to replica synchronization requests, are multi-threaded asynchronous. In other words, multiple modification requests are disorderly, and may be modified first-to-first, modified after.

The multi-threaded asynchronous concurrency control inside ES is based on its own _version version number for optimistic locking concurrency control. When the thread modifies the operation, it compares the _version version number, modifies it if it wants to wait, or loses it if it is not equal, and the thread will no longer perform the modification operation.

Multi-threaded asynchronous concurrency control inside ES

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.