CodesJava

Easy learning with example program codes

what is 2 phase commit in jdbc?


When we work in distributed systems where multiple databases are involved, we are required to use 2 phase commit protocol. 2 phase commit protocol is an atomic commitment protocol for distributed systems.

In the first phase, transaction manager sends commit-request to all the transaction resources. If all the transaction resources are OK, then transaction manager commits the transaction changes for all the resources. If any of the transaction resource responds as Abort, then the transaction manager can rollback all the transaction changes.

Related topics

Posted in JDBC   


Copyright © 2018 CodesJava DMCA.com Protection Status SiteMap