Three-phase commit protocol: Difference between revisions

Content deleted Content added
DBooth (talk | contribs)
Edited to remove ambiguity about which protocol is more failure-resilient
Solution: Minor grammar fix
Tags: Mobile edit Mobile web edit
Line 15:
==Solution==
 
The pre-commit phase introduced above helps the system to recover from the case when a participant failure or both coordinator and participant node failure occurs during the commit phase. When the recovery coordinator takes over after coordinator failure during commit phase of [[two-phase commit]], the new pre-commit comes handy as follows: On querying participants, if it learns that some nodes are in commit phase then it assumes that previous coordinator before crashing has made the decision to commit. Hence it can shepherd the protocol to commit. Similarly, if a participant says that it doesn’t receive PrepareToCommit message, then the new coordinator can assume that the previous coordinator failed even before it completed the PrepareToCommit phase. Hence it can safely assume no other participant would have committed the changes and hence safely abort the transaction.
 
==Extensions==