Comparing Various Methods of Distributed Transactions
Explore the different ways to handle consistency across a distributed system.
We'll cover the following...
In this lesson, we will look at three ways to handle consistency across a distributed system:
Two-phase commit (2PC) can offer the strongest consistency but has some large drawbacks.
The other two are the choreographed saga and the orchestrated saga, which still offer a good consistency model and are excellent options when 2PCs are not an option.
The 2PC
At the center of a 2PC is a coordinator that sends the “Prepare” and “Commit” messages to all the participants. During the Prepare phase, each participant ...