What really flows between APPC systems
This topic describes the commit protocols that flow between APPC systems during a syncpoint.
First, consider a simple distributed process involving only one
conversation, as in
Figure 1
. Here is
what happens:
- The syncpoint initiator sends a "commit" request to the syncpoint agent.
- The syncpoint agent commits all changes it made to recoverable resources, and responds with “committed”.
- The syncpoint initiator then commits its changes, and the UOW is complete.
Figure 1. Syncpoint flows in a single conversation

When the syncpoint agent has a conversation with a third transaction,
Figure 2
shows the flows that occur. Here is
what happens:
- The syncpoint initiator sends a "commit" request to its agent.
- The agent becomes the initiator on the conversation to its agent, and sends a "commit" request.
- The second agent commits first and responds with “committed”.
- The first agent commits and sends "committed" to the initiator.
- The initiator commits.
Figure 2. Syncpoint flows in concurrent conversations

When the syncpoint initiator has two concurrent conversations, the flows involved are shown in Figure 3. Here is what happens:
- The syncpoint initiator sends a "prepare" request to all its agents except one.
- The agent receiving "prepare" responds by sending a "commit" request to the initiator.
- When all the "prepare" requests have been sent, and the "commit" requests received, the initiator sends a “commit” request to its last agent.
- The initiator receives "committed" from the last agent.
- The initiator sends "committed" to the remaining agents.
- The agents respond "forget" to indicate that they do not need to be resynchronized.
Figure 3. Syncpoint flows in concurrent conversations
with one initiator. The initiator uses only SYNCPOINT.

If the syncpoint initiator decides to prepare the conversation
with system 2 explicitly before issuing a syncpoint, the flows involved
are shown in
Figure 4.
In this case,
the application program in system 1 issues an ISSUE PREPARE command,
followed by SYNCPOINT command, rather than just a SYNCPOINT command;
however, the flows across the links are exactly the same as those
in the previous example.
Using the ISSUE PREPARE command gives
the application the opportunity to
"change its mind"
and rollback,
depending on the response to ISSUE PREPARE.
Figure 4. Syncpoint
flows in concurrent conversations with one initiator. The
initiator uses ISSUE PREPARE before SYNCPOINT.

For further information on the flows in a distributed process, see the book LU6.2 Reference: Peer Protocols , SC31-6808.