The X/Open XA interface is an X/Open standard specification that stipulates the interface between a transaction manager (TM) and a resource manager (RM) in a distributed transaction processing (DTP) system. The XA interface enables the transaction manager to control the resource manager's transaction processing. In order for the transaction manager to control the resource manager's transaction processing, a library provided by the resource manager and a library provided by the transaction manager must be linked to an application program.
HiRDB provides the HiRDB XA library to enable a transaction manager to control HiRDB transaction processing. This HiRDB XA library complies with the XA interface specifications based on the X/Open DTP software architecture. Figure 8-1 shows the relationship between HiRDB and the X/Open DTP model.
Figure 8-1 Relationship between HiRDB and X/Open DTP model
Note that if connection is established from a UAP that is using the X/Open XA interface to a recovery-unnecessary front-end server, the SQL statement returns an error. Specify PDFESHOST and PDSERVICEGRP in the client environment definition and connect to a front-end server that is not the recovery-unnecessary front-end server.
Table 8-2 lists the functions supported by the HiRDB XA library.
Table 8-2 Functions supported by HiRDB XA library
Function | Description |
---|---|
Transaction transfer | Executes transaction commit processing by a process other than the one at the time the UAP accessed HiRDB (UAP here refers to the user application program that established the connection with HiRDB using the HiRDB XA library). Whether or not to use the transaction transfer function depends on the PDXAMODE client environment definition operand. For details about the transaction transfer function, see 8.2.4 Transaction transfer. |
Single-phase optimization | Optimizes two-phase commitment control to one phase. When single-phase optimization is used, the transaction completion types of the transaction manager and HiRDB do not always match. For details, see 8.2.11(3) Notes on single-phase optimization. |
Read only | When a HiRDB resource has not been updated by a prepare request, enables the transaction manager to optimize the processing without issuing a commit request at the second phase. |
Dynamic transaction registration | Enables HiRDB to register dynamically a transaction immediately before executing a UAP. |
Multi-connection facility | Executes multiple CONNECTs for HiRDB servers separately from one process. For details about the multi-connection facility in the X/Open XA interface environment, see the manual HiRDB Version 8 UAP Development Guide. |
An XA interface supporting multi-thread enables you to link Object Transaction Service (OTS) with TPBroker and HiRDB.
The multi-thread libraries support only C and C++ languages. They do not support COBOL.
To use an XA interface supporting multi-thread, link a dedicated HiRDB client library. A HiRDB client library version earlier than 05-06 does not support multi-thread. You can use a library for multi-thread with any HiRDB server that supports existing HiRDB clients. The library for multi-thread enables connection to be shared between threads.