Question: What is a JTA/XA/global Transaction?
Answer: The Java™ Transaction API (JTA) allows applications to perform distributed transactions, that is, transactions that access and update data on two or more networked computer resources. The JTA specifies standard Java interfaces between a transaction manager and the parties involved in a distributed transaction system: the application, the application server, and the resource manager that controls access to the shared resources affected by the transactions. This document provides an overview of that process and how the DataDirect Connect® for JDBC™drivers relate to it.
A transaction defines a logical unit of work that either completely succeeds or produces no result at all. A distributed transaction is simply a transaction that accesses and updates data on two or more networked resources, and therefore must be coordinated among those resources. In this document, we are concerned primarily with transactions that involve relational database systems. (E Learning Portal)
The components involved in the distributed transaction processing (DTP) model that are relevant to our discussion are:
- The application
- The application server
- The transaction manager
- The resource adapter
- The resource manager
- In the following sections, we describe these components and their relationship to JTA and database access.