Method of transferring messages between computer programs across a network
First Claim
1. A method of transactional control of message transfer across a transaction-oriented data processing network wherein a sender program is responsible for sending messages from a first node of the network and a receiver program is responsible for receiving messages at a second node of the network, the method comprising:
- sending messages by the sender program within a first syncpoint-manager-controlled unit of work and receiving messages by the receiver program within a second syncpoint-manager-controlled unit of work, while holding the sending and receiving operations in-doubt, uncommitted, until resolution of the first and second units of work, respectively, wherein the first syncpoint-manager-controlled unit of work and the second syncpoint-manager-controlled unit of work are logically linked so that commit processing at resolution of said units of work comprises the steps of;
in response to successful receipt of the messages by the receiver program, performing the sequence of steps of committing said second unit of work, transmitting to the sender program a positive confirmation of receipt, and in response to the positive confirmation committing the first unit of work;
or in response to unsuccessful receipt of the messages, performing the sequence of steps of rolling back the second unit of work, transmitting to the sender program a negative confirmation of receipt, and in response to said negative confirmation backing out the first unit of work.
0 Assignments
0 Petitions
Accused Products
Abstract
A method of delivering messages between application programs is provided which ensures that no messages are lost and none are delivered more than once. The method uses asynchronous message queuing. One or more queue manager programs (100) is located at each computer of a network for controlling the transmission of messages to and from that computer. Messages to be transmitted to a different queue manager are put onto special transmission queues (120). Transmission to an adjacent queue manager comprises a sending process (130) on the local queue manager (100) getting messages from a transmission queue and sending them as a batch of messages within a syncpoint-manager-controlled unit of work. A receiving process (150) on the receiving queue manager receives the messages and puts them within a second syncpoint-manager-controlled unit of work to queues (180) that are under the control of the receiving queue manager. Commitment of the batch is coordinated by the sender transmitting a request for commitment and for confirmation of commitment with the last message of the batch, commit at the sender then being triggered by the confirmation that is sent by the receiver in response to the request.
The invention avoids the additional message flow that is a feature of two-phase commit procedures, avoiding the need for resource managers to synchronise with each other. It further reduces the commit flows by permitting batching of a number of messages.
-
Citations
9 Claims
-
1. A method of transactional control of message transfer across a transaction-oriented data processing network wherein a sender program is responsible for sending messages from a first node of the network and a receiver program is responsible for receiving messages at a second node of the network, the method comprising:
-
sending messages by the sender program within a first syncpoint-manager-controlled unit of work and receiving messages by the receiver program within a second syncpoint-manager-controlled unit of work, while holding the sending and receiving operations in-doubt, uncommitted, until resolution of the first and second units of work, respectively, wherein the first syncpoint-manager-controlled unit of work and the second syncpoint-manager-controlled unit of work are logically linked so that commit processing at resolution of said units of work comprises the steps of;
in response to successful receipt of the messages by the receiver program, performing the sequence of steps of committing said second unit of work, transmitting to the sender program a positive confirmation of receipt, and in response to the positive confirmation committing the first unit of work;
orin response to unsuccessful receipt of the messages, performing the sequence of steps of rolling back the second unit of work, transmitting to the sender program a negative confirmation of receipt, and in response to said negative confirmation backing out the first unit of work. - View Dependent Claims (2, 3, 4, 5, 6)
a first application program issuing a put message instruction under control of a synchpoint manager in the sending computer system, for sending a message to a message queue;
sender and receiver transmission programs transferring messages between the computer systems, as two logically linked units of work, using synchpoint managers in both the sending and receiving computer systems; and
a second application program issuing a get message instruction under control of a synchpoint manager in the receiving computer system, for taking the message from the queue;
wherein the operations of put message, transfer and get message are each held in-doubt until resolution of the respective unit of work.
-
-
7. A data processing system including a messaging manager for transactional control of message transfer across a network of data processing systems, the messaging manager including sender and receiver programs for transferring messages between adjacent messaging managers in the network in accordance with the following transfer protocol:
-
a sender program of a first messaging manager sending one or more messages within a first syncpoint-manager-controlled unit of work;
a receiver program in a second messaging manager receiving said messages within a second syncpoint-manager-controlled unit of work;
the sending and receiving operations being held in-doubt, uncommitted, until resolution of the first syncpoint-manager-controlled unit of work and the second syncpoint-manager-controlled unit of work, respectively; and
said first and second units of work being logically linked so that commit processing at resolution of said first and second units of work comprises either (i) in response to successful receipt of the messages by the receiver program, committing said second unit of work, transmitting to the sender program a positive confirmation of receipt, and in response to the positive confirmation committing the first unit of work;
or(ii) in response to unsuccessful receipt of the messages, rolling back the second unit of work, transmitting to the sender program a negative confirmation of receipt, and in response to said negative confirmation backing out the first unit of work. - View Dependent Claims (8)
-
-
9. A computer program product comprising computer program code recorded on a computer-readable recording medium, the computer program code implementing a messaging manager for transactional control of message transfer across a network of data processing systems, the messaging manager including sender and receiver programs for transferring messages between adjacent messaging managers in the network in accordance with the following transfer protocol:
-
a sender program of a first messaging manager sending one or more messages within a first syncpoint-manager-controlled unit of work;
a receiver program in a second messaging manager receiving said messages within a second syncpoint-manager-controlled unit of work;
the sending and receiving operations being held in-doubt, uncommitted, until resolution of the first syncpoint-manager-controlled unit of work and the second syncpoint-manager-controlled unit of work, respectively; and
said first and second units of work being logically linked so that commit processing at resolution of said first and second units of work comprises either (i) in response to successful receipt of the messages by the receiver program, committing said second unit of work, transmitting to the sender program a positive confirmation of receipt, and in response to the positive confirmation committing the first unit of work;
or(ii) in response to unsuccessful receipt of the messages, rolling back the second unit of work, transmitting to the sender program a negative confirmation of receipt, and in response to said negative confirmation backing out the first unit of work.
-
Specification