Roles in commit processing

If a commit of a transaction involves more than one resource manager, each resource manager plays a role in the transaction. A resource manager is responsible for committing or rolling back changes made during the transaction.

The resource managers by resource type are:

FILE
Database manager
DDM
Database manager
DDL
Database manager
DRDA®
Communications transaction program
LU62
Communications transaction program
API
API exit program

The following figures shows the basic roles in a transaction. The structure shown in the figures is called a transaction program network. The structure can be in a single-level tree and a multilevel tree.

Roles in two-phase commit processing: Single-level tree

When an application on System A issues a commit request, the resource manager on System A becomes the initiator. For DRDA distributed unit of work over TCP/IP, the initiator is called the coordinator.

The resource managers for the other three systems (B, C, and D) become agents for this transaction. For DRDA distributed unit of work over TCP/IP, agents are sometimes called participants.


This figure explains roles in two-phase commit processing. It shows a network of four servers in a single level tree. System A is the tree of the network, and Systems B, C, and D branch from it. The text following the image explains what each system is for.

Roles in two-phase commit processing: Multi-level tree

If the application is using APPC communications to perform the two-phase commit, the relationship between systems can change from one transaction to the next. The following figure shows the same systems when an application on System B issues the commit request. This configuration is a multi-level tree.

The roles in this figure do not apply to DRDA distributed unit of work over TCP/IP because multi-level transactions trees are not supported.


This figure explains roles in two-phase commit processing. It shows a network of four servers in a multi-level tree. System B communicates directly to System A. The network from System A, then branches to System C and System D. The text following the image explains what each system is for.

The transaction program network has another level because System B is not communicating directly with System C and System D. The resource manager in System A now has the roles of agent and cascaded initiator.

To improve performance of LU 6.2 two-phase transactions, the initiator might assign the role of last agent to one of the agents. The last agent does not participate in the prepare wave. In the committed wave, the last agent commits first. If the last agent does not commit successfully, the initiator instructs the other agents to roll back.

For DRDA distributed unit of work over TCP/IP, the coordinator might assign the role of resync server to a participant. The resync server is responsible to resynchronize the other participants in the event in which there is a communications failure with the coordinator, or the coordinator has a systems failure.

Related concepts
Commitment definition for two-phase commit: Allow vote read-only