In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
This article will explain in detail what is the paxos protocol, the content of the article is of high quality, so the editor will share it with you for reference. I hope you will have a certain understanding of the relevant knowledge after reading this article.
Solve the problem: how to ensure that multiple Proposer and Acceptor eventually get a consistent proposal when the message is likely to be lost.
Theoretical requirements:
1. An acceptor must approve his first proposal.
two。 There is a set of more than half of acceptor s, either s has not been approved, or s has approved the proposal, the maximum number is less than Mn, and the value is Vn, then the proposal [Mn,Vn] will be approved.
Acceptor workflow:
1. If Acceptor proposes that the Mn of prepared is larger than that approved by him, he will no longer receive a version number that is less than Mn, but will approve one that is greater than Mn. And returns the value value of the approved maximum version number that is less than Mn
Proposer workflow:
1. Send an prepared request to all Acceptor, and if more than half of the response is received, proceed to the next step.
two。 If you already have a value in the response you receive, you can only select the value with the highest version number as the value for your proposal. If there is no value, you can choose whatever you want.
Optimization:
1.leanrer is also a cluster. If both learner and acceptor are connected, the number of communications will be excessive. If there is only one learner, it is easy to hang up. Then the optimal solution is to select a part of learner as the cluster.
two。 It will happen that when p1 prepared, acceptor approves, and in the process of submitting the proposal, acceptor prepare a higher version number, causing his proposal to be ignored, resulting in a "live lock". So the solution is to use a single Proposer.
On what is the paxos agreement to share here, I hope that the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 277
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.