Transaction management using JTA
The three project versions of this chapter use JTA as the transaction manager, just in case the system gets huge scope implementing more than one data source. Previous chapters highlighted that Spring MVC 4.x uses JDBC as the interface to connect to databases and were also successful in implementing the JPA entity manager that uses @PersistenceContext for in-memory collection of entities, which isolates the application from the inner workings of JDBC and database operations. Any CRUD done in the entities automatically updates the tables in the databases.
However, this chapter implements JTA allowing OCS for management of multiple transactions among multiple databases in the future. It is still JPA which will utilize ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access