

Two-Phase Commit Processing › Two-Phase Commit › X/Open Distributed Transaction Processing
X/Open Distributed Transaction Processing
To understand how a two-phase commit works within a CA Gen Distributed Processing (DP) application, you can find it useful to understand how the X/Open definitions relate to CA Gen processing.
The X/Open Distributed Transaction Processing (DTP) model defines the following separate entities that participate in a distributed application:
- Application Program (AP)
- Transaction Manager (TM)
- Resource Manager (RM)
The following illustration shows the relationships among these three entities:

The Transaction Manager or TM is responsible for managing transactions on behalf of the application. The AP is the CA Gen server application code that executes under the control of a Transaction Manager. The CA Gen server application issues transactional statements to the Resource Manager or RM. The Resource Manager for CA Gen is the Database Management Software (DBMS) that manages access to the data as follows:
- The interface between the AP and RM is generally SQL. No specification is given for this interface. Servers open a connection to the RM through the XA API xa_open(). This establishes a connection to the RM for global transactions. At server shutdown, the XA API xa_close() closes the connection. These XA APIs are managed through the vendor software hosting the CA Gen server applications. For example, Tuxedo provides the tpopen() and tpclose() API call for use by the generated Tuxedo server.
- The execution environment hosting the CA Gen server applications manages the interface between the TM and RM. There are many procedural interfaces that are defined for XA-compliant RMs (for example, xa_open(), xa_start(), xa_end(), xa_prepare(), xa_commit(), and xa_recover()). It is through these interfaces that the TM communicates with the RM, on behalf of the AP.
- The interface between the AP and TM is mainly through transactional APIs provided by the server execution environment. For example, Tuxedo provides the following APIs; tpbegin(), tpcommit() and tpabort().
Copyright © 2014 CA.
All rights reserved.
 
|
|