ACID Property With Two Phase Commit
ACID Property With Two Phase Commit
1. Atomicity:
The 2PC protocol achieves atomicity by breaking the transaction
commitment process into two phases:
2. Consistency:
2PC maintains consistency by ensuring that all participants either
commit or abort the transaction. If any participant is unable to
commit or encounters an error, the protocol ensures that the entire
transaction is rolled back, avoiding inconsistent states where some
participants have committed while others have not.
3. Isolation:
Isolation, which ensures that concurrent transactions do not
interfere with each other's outcomes, is typically maintained at the
individual database or resource manager level through concurrency
control mechanisms. 2PC itself does not impact isolation directly.
4. Durability:
The durability property ensures that once a transaction is
committed, its changes are permanent and survive system failures.
2PC ensures durability by following a coordinated approach: