Abstract:
Responsive to a client application initiating a synchronous communication with a server application by sending a request via an asynchronous communication manager, one or more checks are performed to identify a cause of any failure to provide a response to the client application satisfying synchronous communication criteria. The results of one or more checks are used to determine whether to back out any data updates performed by/on behalf of the server application in response to the request.

Description:
FIELD OF THE INVENTION  
       [0001]     The present invention relates to the field of asynchronous messaging, and more particularly to the use of such technology for pseudo conversational messaging.  
       BACKGROUND OF THE INVENTION  
       [0002]     A number of different types of messaging communication models currently exist.  
         [0000]     i) Synchronous messaging where a client sends a message to a server and requires a response before client processing proceeds. The client is unable to perform additional work until a response is received from the server,  
         [0000]     ii) Asynchronous messaging where a client puts a request to a queue for background processing. The client can in the meantime process other work, safe in knowledge that a response will be received at some point.  
         [0003]     iii) Pseudo Conversational Messaging where asynchronous messaging technology is used to send and receive messages but nevertheless, the client and server are expecting synchronous communication with one another, or any other differences between the client and server system capabilities.  
         [0004]     The third model of communication is a common use of asynchronous messaging technology (for example IBM&#39;s WebSphere® MQ product). Note that this use of the words “client” and “server” refers to the logical relationship between the two computer systems and does not necessarily imply that the client computer system is using (for example) a WebSphere MQ client connection to a WebSphere MQ queue manager in the server computer system.  
         [0005]     Typically, asynchronous messaging is chosen for reasons that include:  
         [0000]     i) it provides simple interfaces to the programs running in the client system and the server system.  
         [0000]     ii) It is available for a wide range of systems (computers, operating systems, and other software)  
         [0000]     iii) It enables use of integration software (for example, IBM&#39;s WebSphere® Business Integration Message Broker)  
         [0000]     iv) Many users prefer to use a single messaging technology so that they benefit from consistent operations and system management.  
         [0006]     A pseudo-conversational messaging system is shown with reference to  FIG. 1 . Using pseudo-conversational asynchronous messaging, a client computer application  10  prepares a message (the request) and issues a PUT verb (step  1 ) to send the message to remote request queue  40 . In accordance with asynchronous messaging practices client queue manager  70  first places the message on a local transmit (xmit) queue  20 . The client queue manager then transmits the message from the local xmit queue  20  to server remote request queue  40 , hosted on server queue manager  80  (step  2 ). Server application  30  issues a GET verb to retrieve the message (step  3 ), processes the message at step  4  (that is, performs the requested service), and PUTs a response message (step  5 ) to send the response message to the reply to queue  60  specified in the request message. The server queue manager first places the response message on its xmit queue  50  and then transmits the message to the client&#39;s local reply-to queue  60  (step  6 ). The client application  10  issues a GET verb to get the response message (step  7 ).  
         [0007]     The server application uses transactional semantics so that the GET of the request, the processing, and the PUT of the response are either all completed (COMMIT) or are all backed out (BACKOUT or ABORT).  
         [0008]     The client application however cannot simply include its PUT of the request (step  1 ) and its get of the response (step  7 ) in the same transaction. This is because the request message is not delivered to the server queue manager until the transaction that contains it COMMITS. The client application would lock-up indefinitely waiting for a response from the server before committing its transaction, yet the server application would not have received a request to process because the transaction had not committed.  
         [0009]     The difficulty including steps 1 and 7 together in a transaction creates a problem for the client application regarding the appropriate behavior when no response message from the server application has been received within a reasonable period of time. This is particularly true because this model of messaging is pseudo-conversational (synchronous), rather than being true asynchronous messaging.  
         [0010]     Thus when the client application does not receive a response from the server application, the client application is unsure as to whether its request has beenlor will be processed by the server application.  
         [0011]     Numerous techniques have been devised to deal with this problem. For example, the client application can specify a time-out value with the request. In this case, the message will be discarded if it cannot be delivered to the server application before the time expires. However, even in this case, the client application cannot assume that “no response” means the requested function was not performed. It might be that the response message from the server application has been delayed by, for example, network problems.  
         [0012]     The client application could alternatively decide, having heard nothing, that the processing worked. Such an assumption could however be incorrect. It rather depends how important the client application&#39;s request was as to how much an incorrect assumption matters.  
         [0013]     A compensating transaction can be used to compensate for the situation where it is wrongly assumed that a previous transaction did or did not happen. The compensating transaction negates the effects of the wrong assumption. It is however generally difficult for a program to generate a compensating transaction automatically.  
         [0014]     Another option is to periodically poll (e.g. after a timeout period) the client application queue manager (which can in turn poll the server application&#39;s queue manager). This however adds additional (typically unwanted) complexity to the client application.  
       SUMMARY OF THE INVENTION  
       [0015]     According to a first aspect, there is provided a method for facilitating communication between a client application and a server application, the method comprising: responsive to the client application initiating a synchronous communication with the server application by sending the request via an asynchronous communication manager, performing one or more checks to identify a cause of any failure to provide a response to the client application satisfying synchronous communication criteria; and using the results of one or more of the checks to determine whether to back out any data updates(changes) performed by/on behalf of the server application in response to the client application&#39;s request.  
         [0016]     Preferably the checks comprise checking each of a set of resources and a sequence of resource updates required to provide a response to the client application. Note, only one or more of a possible set of checks may be performed. By way of example, a resource may be a queue, a communications link etc. By way of example a resource update may involve putting a message to a queue, getting a message from a queue etc  
         [0017]     The asynchronous communication manager may comprises a client application&#39;s queue manager and a server application&#39;s queue manager.  
         [0018]     According to a preferred embodiment, the server application&#39;s queue manager forwards the server application&#39;s response to the client application&#39;s request for receipt by the client application. In response to successful delivery of the response to the client application the client application&#39;s queue manager informs the server application&#39;s queue manager that it is acceptable to finalise any changes necessitated by the client application&#39;s request with one or more resources,  
         [0019]     Preferably the aforementioned one or more checks comprises at least one of:  
         [0000]     i) checking at the client application&#39;s queue manager that the request message is appropriately specified,  
         [0000]     ii) checking that a communication&#39;s link to the server application&#39;s queue manager is working,  
         [0000]     iii) checking that a request queue, hosted by the server application&#39;s queue manger, is able to receive the client application&#39;s request;  
         [0000]     iv) checking that the request is retrieved by the server application;  
         [0000]     v) checking that a response is put to transmit queue hosted by the server application&#39;s queue manager;  
         [0000]     vi) checking that the communication&#39;s link to the client application&#39;s queue manager is working;  
         [0000]     vii) checking that a reply to queue, hosted by the client application&#39;s queue manager, is able to receive the response; and  
         [0000]     viii) checking that the client application retrieves the server application&#39;s response from the reply to queue.  
         [0020]     Preferably if it is determined that the request queue is unable to accept the client application&#39;s request, a notification is created for administrator attention.  
         [0021]     Preferably if it is determined that the request is not retrieved by the server application (e.g. within a predetermined time period), a notification is created for administrator attention.  
         [0022]     In accordance with a preferred embodiment, the server application&#39;s queue manager requests that any resource managers involved in processing the client application&#39;s request guarantee that the are able to finalise any changes necessitated by the client application&#39;s request.  
         [0023]     If this is not possible, the server application&#39;s queue manager preferably requests that the resource managers undo any changes made on behalf of the server application.  
         [0024]     Preferably, responsive to any such resource managers being able to make such a guarantee, it is logged that a response is to be sent to the client application&#39;s queue manager.  
         [0025]     Preferably the server application is provided with a predetermined amount of time in which to retrieve the client application&#39;s request from the server application&#39;s queue manager.  
         [0026]     Preferably the client application is provided with a predetermined amount of time in which to retrieve the server application&#39;s response from the client application&#39;s queue manager.  
         [0027]     In accordance with a preferred embodiment, while waiting for an indication from the client application&#39;s queue manager of successful delivery of the server application&#39;s response, the server application&#39;s queue manager checks that the communication&#39;s link between the client application&#39;s queue manager and the server application&#39;s queue manager is working. Responsive to determining that the communication&#39;s link is not working, any changes necessitated by the client application&#39;s request are preferably finalized with one or more resources. A notification that an error may have occurred can be provided for administrator attention. Heartbeating technology is preferably used to determine whether the communication&#39;s link is working.  
         [0028]     In the situation where the server application&#39;s queue manager has failed subsequent to sending a response to the client application&#39;s request, but prior to confirmation of delivery of the response to the client application, the situation is preferably as follows. Upon restart of the server application&#39;s queue manager and responsive to detecting logged information that a response was sent, any changes necessitated by the client application&#39;s request are preferably finalized with one or more resources, A notification that an error may have occurred is preferably provided for administrator attention.  
         [0029]     In the situation where the server application&#39;s queue manager has failed prior to sending a response to the client application&#39;s request, the situation is preferably as follows. Upon restart of the server application&#39;s queue manager and responsive to detecting that there is no logged information that a response was sent, it is preferably requested that the server application undo any changes necessitated by the request and abort processing.  
         [0030]     In accordance with a preferred embodiment the client application&#39;s request is only transmitted from the client application&#39;s queue manager to the server application&#39;s queue manager, when the client application attempts to retrieve the server application&#39;s response.  
         [0031]     According to a second aspect, there is provided an apparatus for facilitating Communication between a client application and a server application, the apparatus comprising; means, responsive to the client application initiating a synchronous communication with the server application by sending the request via an asynchronous communication manager, for performing one or more checks to identify a cause of any failure to provide a response to the client application satisfying synchronous communication criteria; and means for using the results of one or more of the checks to determine whether to back out any data updates performed by/on behalf of the server application in response to the request.  
         [0032]     The invention may be implemented in computer software.  
         [0033]     According to one embodiment, the invention provides a method for a client application to communicate synchronously with a server application using asynchronous messaging software, the method comprising; receiving a client application request at the client application&#39;s queue manager for processing by the server application, if possible, forwarding the request to the server application&#39;s queue manager for retrieval by the server application, if possible, forwarding a response from the server application to the client application&#39;s queue manager for retrieval by the client application; performing checks to determine when the client application&#39;s request or the server application&#39;s response is unable to reach its intended recipient synchronously; and responsive to determining that they request or response is unable to reach its intended recipient, undoing any processing by the server application as a result of the client application&#39;s request. 
     
    
     BRIEF DESCRIPTION OF THE DRAWINGS  
       [0034]     A preferred embodiment of the present invention will now be described, byway of example only, and with reference to the following drawings:  
         [0035]      FIG. 1  illustrates the components and processing steps involved in a pseudo-conversational messaging system; and  
         [0036]      FIGS. 2   a ,  2   b ,  2   c  and  2   d  disclose the components and processing involved in a preferred embodiment of the present invention. 
     
    
     DETAILED DESCRIPTION OF THE INVENTION  
       [0037]     As discussed pseudo-conversational messaging suffers from the “no-response problem”. In other words, a client application receiving no response from a request, is left wondering whether the request was processed/will be processed by a server application. There are a number of possibilities.  
         [0000]     i) It could be that the request never reached the server application/queue manager in the first place;  
         [0000]     ii) The server application/queue manager could just be processing requests particularly slowly;  
         [0000]     iii) The server application/queue manager might have failed; or  
         [0000]     iv) The server application&#39;s response might be delayed reaching the client application.  
         [0038]     The client application is therefore left in an uncertain situation.  
         [0039]     This invention, in accordance with a preferred embodiment, seeks to resolve such uncertainty by introducing novel processing into the client and server queue managers (messaging software) such that the client application can be developed without the use of complex code to handle the no-response-received case.  
         [0040]     The client application is able to assume that if no response message is received within a reasonable time (preferably chosen by the client application) then the requested service has not been (and will not be) performed. The special processing includes provision for notifying an administrator in certain (very rare) cases where this assumption fails. The administrator is required to deal with these cases in much the same way as when a messaging system puts an undeliverable message on the so-called “dead letter queue” for administrative attention (IBM WebSphere MQ product).  
         [0041]     Note for the sake of clarity, processing is described using the assumption that the servers queue manager is acting as the transaction coordinator for the server. It is also assumed that the client application does its PUTs and GETs out of transaction.  
         [0042]     The behavior of the present invention may be specified in one of a number of ways: 
    1) an extra option is provided that the client application specifies at PUT time (this requires modification to existing applications)     2) an attribute is added to a remote queue definition. E.g. the client queue manager can create a definition of a remote queue such as the request queue and can then inform the server application&#39;s queue manager that the behaviour of the invention is required, Alternatively, the server application&#39;s queue manager can also define an attribute on its own local request queue.     3) an attribute is added on the client application (this is set by an administrator when deploying/installing the application)    
 
         [0046]     Options which do not require changes to existing client or server application code (i.e. only requiring changes to the messaging software itself) are particularly advantageous.  
         [0047]     On the other hand, some customers might want existing client applications to carry on working the way they always have. Such customers might prefer the flexibility of having the client application specify whether they want the “old” behavior (i.e. not use the functionality disclosed) or the “new” behavior (i.e. use the disclosed functionality). This would imply a new option that the client application could invoke.  
         [0048]     In one embodiment, both of the above approaches are catered for (queue attribute and client option).  
         [0049]     The preferred embodiment will now be described with reference to  FIGS. 2   a ,  2   b ,  2   c  and  2   d .  FIG. 2   a  is similar to  FIG. 1 . The componentry is the same, as are the reference numerals identifying such componentry. Some additional information is provided relating to certain checks that are performed. These checks are detailed on  FIG. 2   a . Additional processing steps are illustrated in  FIGS. 2   b ,  2   c  and  2   d . The figures should all be read in conjunction with one another.  
         [0050]     As alluded to above, the messaging software has a number of checks to perform. The first set of checks are used so that the client application can be sure that its request actually reached the server&#39;s queue manager. All checks will be described as and when they occur during processing,  
         [0051]     Client application  10  PUTs a request to client queue managers  70  local xmit queue  20  (step  100 ). Client queue manager  70 , at this point, performs check A (step  110  in  FIG. 2   b ).  
         [0052]     Check A  
         [0053]     Client&#39;s queue manager  70  checks that the message is appropriately specified. For example, the message should specify a reply-to queue  60  to accommodate the server application&#39;s response.  
         [0054]     If the message is not appropriately specified, the client&#39;s queue manager returns “failed” to the client application for the PUT request (step  115 ). Consequently the request will not be forwarded onto the server application&#39;s queue manager and the client application can safely assume that its request has not and will not be processed by the server application.  
         [0055]     Otherwise check B is performed (step  120 ).  
         [0056]     Check B  
         [0057]     The client&#39;s queue manager  70  checks if the communication link to server queue manager  80  is available.  
         [0058]     If the link is not available, the client queue manager returns “failed” to client application  10  for the PUT request (step  125 ). Once again the request will not be forwarded to the server application&#39;s queue manager, and so the client application can safely assume that its request has not and will not be processed by the server application.  
         [0059]     Note, normal asynchronous behavior is if the communications link is down, a client application&#39;s request will remain on the client queue managers xmit queue until the link is up again. However in this instance, such behaviour is not appropriate since the client application is waiting for a response to the client&#39;s request—in other words the client application is employing a pseudo conversational (or synchronous) communications model.  
         [0060]     Assuming that the communication&#39;s link is up, the client&#39;s queue manager  70  transmits the request message from the client&#39;s local xmit queue  20  to the servers queue manager  80  (step  130 ).  
         [0061]     When the request is received by the server queue manager  80 , the queue manager performs check C (step  140 ).  
         [0062]     Check C  
         [0063]     The server&#39;s queue manager  80  verifies if there is any reason why the request message cannot be added to the servers remote request queue  40  immediately. For example, the message may be too large, the queue  40  may be full; the queue may be PUT inhibited.  
         [0064]     If there is any reason why the server&#39;s queue manager cannot accept the client&#39;s request, the servers queue manager deletes the request message (step  145 ). Consequently the server application will not process the client application&#39;s request.  
         [0065]     Optionally, the servers queue manager can send a report or other notification for retrieval by an administrator (not shown). This could be written to for example, to a dead letter queue.  
         [0066]     Assuming the request is accepted, the server queue manager  80  then performs check D (step  150 ).  
         [0067]     Check D  
         [0068]     A check is performed to determine whether a server application  30  performed a GET (step  150 ) to retrieve the request message within a configurable (but preferably short amount of time).  
         [0069]     If the server application fails to perform the GET in time, or (in a simple embodiment) if the server application backs out the GET, the server&#39;s queue manager deletes the request message (step  155 ). In a more sophisticated embodiment, if the server application backs out the GET, the server&#39;s queue manager can permit some retries, Thus, if the server backs out the GET, the servers queue manager returns the request message to the request queue so that the server application can try again. However, after a specified number of retry attempts and/or after a specified amount of time doing these retries, the servers queue manager preferably deletes the message (to avoid an infinite retry loop). Optionally, the server&#39;s queue manager can send a report or other notification for retrieval by an administrator. This could be written to, for example, a “dead letter queue.” 
         [0070]     Note, it is not essential that the server application be given x seconds (or milliseconds) in which to GET the client application&#39;s request but this is preferable since (as discussed above) the GET may not work property. If the server application is slow to GET the request (or does not GET the request at all), then the client application will get bored and give up waiting for the response. When (if) the server application does eventually GET and process the request, then check H, which shall be subsequently discussed in reater detail, will fail (no client application GET for the response) and step  255  (see  FIG. 2   d ) will ABORT the server application&#39;s transaction. Thus, there is no harm done, but the server application has wasted time and energy processing the request too late.  
         [0071]     Note, it is optional for the server queue manager to send a report or other notification (as a result of checks C and D) because the client application is configured to interpret “no reply” as meaning that the requested action was not performed. This is the correct interpretation in the cases mentioned, However, a report or other notification could provide the administrator with useful additional information (e.g. that a request has failed and why it failed).  
         [0072]     Assuming that the request message is retrieved (GOT) by the server application  30 , server application  30  processes the request (step  160 ) and PUTS a response to server queue managers reply to remote xmit queue  50  (step  170 ). Note, if check C or D results in request deletion then no processing will be performed by the server application as a result of the client application&#39;s request.  
         [0073]     A second set of checks are performed so that the client can be sure that the server application&#39;s response, if sent, is received. Again, such checks are depicted using the figures (starting with  FIG. 2   c ).  
         [0074]     Server queue manager  80  performs one such check—check E (step  180 )  
         [0075]     Check F  
         [0076]     A check is performed by the server&#39;s queue manager to determine whether there is any reason why the server application&#39;s response cannot be PUT to xmit queue  50 .  
         [0077]     If the server queue manager is unable to PUT the response, failure is returned. Such a failure will cause the server application to outback its transaction, and, consequently, the server application will not perform any processing as a result of the client application&#39;s request (step  185 ).  
         [0078]     If on the other hand, it is possible to PUT the response, check F is then performed (step  190 ).  
         [0079]     Check F  
         [0080]     The servers queue manager checks if the communication link to the client system is available.  
         [0081]     If not, it returns “failed” to the PUT request. Such a failure will cause the server to backout its transaction, and, consequently the server application will not perform any processing as a result of the client application&#39;s request (step  195 ).  
         [0082]     Otherwise, server queue manager  80  returns “succeeded” to the PUT request (step  200 ).  
         [0083]     A response of “succeeded” causes the server queue manager to proceed and (assuming no other problems are identified by the server application), it is expected that the server application will commit (not a commit in the true sense of the word—see below) its transaction (step  210 ),  
         [0084]     The servers queue manager (acting as transaction coordinator) then Issues a PREPARE against ail resource managers (R Ms) other than the queue manager itself (this is as per “last agent optimization”) at step  220 . Such a PREPARE causes all the RMs to “harden” (typically “harden” means “write out to their log”) enough information to ensure they will be able to complete (or backout) their part of the transaction when asked to do so by the transaction coordinator (in this case, the server queue manager). (Resource managers may include, for example, database managers controlling databases against which changes may be made as a result of the client application&#39;s request (server application processing).  
         [0085]     If any RM returns “failed” then the servers queue manager ABORTS the transaction and the server queue manager (and any other RMs) backout (step  225 ).  
         [0086]     Otherwise, the server&#39;s queue manager writes a “provisional go” record for the transaction to its log (step  230 ). The “provisional go” is the server queue manager&#39;s way of logging that the servers queue manager is about to send a response to the client application&#39;s request, Such a provisional go record is useful for error recovery purposes. This will be explained later.  
         [0087]     The servers queue manager then transmits the response message to the client&#39;s queue manager  70  at step  240 . In conventional asynchronous messaging, the server&#39;s queue manager does not transmit the response message until commit processing for the server application is complete. At this stage, the server application&#39;s commit has been prepared but is not yet complete (and, as discussed below, might still get aborted).  
         [0088]     In other words the server application&#39;s commit at step  210  is not a commit in the true sense of the word. The server application&#39;s commit asks the transaction coordinator to ask the RMs to commit (conventional 2PC). The transaction coordinator (in this case, the server queue manager) PREPARES all RMs (conventional, phase 1), it writes a “provisional go” record to its log (not shown) and sends the server application&#39;s response to the client&#39;s queue manager, It does not precipitate any updates (other changes) to be COMMITTED to back-end databases etc. Normally the transactional COMMIT would also cause such changes to be made with back-end systems.  
         [0089]     Eventually the transaction coordinator decides everything is OK and forward completes at step  280  or decides everything is not OK and aborts (conventional, phase 2) at step  225  or step  246  or  255 . This is all discussed below,  
         [0090]     Returning to the sequence of processing in  FIG. 2   c , if the transmission fails at step  240 —for example, if the communication link is not available—the server&#39;s queue manager (acting as transaction coordinator) ABORTS the server application&#39;s transaction (step  241 ). Otherwise, it awaits a response.  
         [0091]     Note, check F has already been performed at step  190  but the communications link may fail subsequently (i.e. in between returning an indication of success to the server application (step  200 ) and the actual attempt to transmit a response (step  240 ). For example, the server application may be told that the link is working, do some processing and then commit the transaction. The link may fail between the additional processing and the server applcation&#39;s commit.  
         [0092]     Assuming that the transmission at step  240  worked and the response is received by the client queue manager  70 , then queue manager  70  performs check G (step  245 ).  
         [0093]     Check G  
         [0094]     The client queue manager performs check G in order to determine whether it is possible to PUT the response onto local reply to queue  60 ,  
         [0095]     If it is not possible, a response of failed is returned to the server queue manager and this causes it to abort the server application&#39;s transaction (step  246 ).  
         [0096]     Otherwise, check H is performed (step  250 )  
         [0097]     Check H  
         [0098]     Client&#39;s queue manager checks whether the client application GETs the response message within a configurable (but short) amount of time. If the client application does not GET the response(s) within this time, the client&#39;s queue manager deletes the response message(s) and sends a “failed” signal to the servers queue manager. The server&#39;s queue manager (acting as transaction coordinator) ABORTS the server application&#39;s transaction (step  255 ).  
         [0099]     Otherwise, the clients queue manager delivers the message (step  260 ) and sends a “succeeded” signal to the server&#39;s queue manager  80  (step  270 ). The server&#39;s queue manager (acting as transaction coordinator) “forward completes” the server application&#39;s transaction (step  280 ).  
         [0000]     By providing the client application with x seconds (or milliseconds) in which to GET the server application&#39;s response, the amount of time that the server application&#39;s transaction is in-doubt is minimised.  
         [0100]     It will be appreciated that it is possible for the GET to fail, For example, the GET could timeout or the message may be too large for the client application to accept. If the GET does fail, step  255  should be processed as soon as possible to back-out the server applications transaction.  
         [0101]     Note, the server queue manager can force transaction abort at step  255  (check H). Unlike the situation described with reference to check D, there is no point in allowing retries for this case since the client application is obviously not available. Thus, the queue manager could permit some retries for “ordinary” back-out or abort situations but not permit retries (i.e. delete the request message) for aborts which it itself forced at step  255 . Thus in this situation a back-out/abort does not result in the client application&#39;s request being put back on the request queue  40 . Note, the client queue manager would have to provide an indication of the reason for failure—i.e. that it was as a result of check H.  
         [0102]     From the foregoing, it should now be appreciated that client application&#39;s GET of the server&#39;s response is made part of the server application&#39;s transaction. The server queue manager (acting as transaction coordinator) “forward completes” the server application&#39;s transaction once the client queue manager has confirmed receipt by the client application of the server application&#39;s response,  
         [0103]     Otherwise the server queue manager will abort the transaction. In this way the client application can be sure that either it will receive a response from the server queue manager or the transaction will be aborted.  
         [0104]     Once the server queue manager “forward completes” the transaction, back-end databases etc. are updated (finalized) in accordance with the client application&#39;s request (step  290 ) and the request message is finally deleted off the request queue  40  (step  295 ).  
         [0105]     It is apparent that the server application&#39;s transaction is in-doubt from when the response message is transmitted (step  240 ) until the status signal (“failed” or “succeeded”) is received from the client&#39;s queue manager (step  270 ).  
         [0106]     In conventional transaction processing, the transaction would remain in-doubt until the client&#39;s queue manager definitively reports its outcome. However it is understood that a long in-doubt state is highly undesirable in high performance servers For example, database and other locks are held until the transaction is resolved, creating log-jams in the server (e.g. server queue manager, resource managers, resources, server application).  
         [0107]     Such a problem is resolved in the following novel way:  
         [0108]     i) If after step  240 , but before step  270 , the servers queue manager  80  detects that the link to the client&#39;s queue manager  70  has failed or that the client queue manager has failed, then (acting as transaction coordinator) it COMMITS the transaction.  
         [0109]     (The server queue manager knows whether it sent the response and whether the communications link was up at the time due to the response at step  240 .)  
         [0110]     Before indicating that participating RMs should also “forward complete”, the server&#39;s queue manager creates and hardens a “commit possibly not notified” report for an administrator who must investigate and take action as appropriate.  
         [0111]     This processing is analogous to the established WebSphere MO dead-letter queue concept. When a WebSphere MO messaging system is contracted (transactionally) to deliver a message but later discovers it cannot do so then it puts the message on the dead-letter queue for administrative attention.  
         [0112]     It is desirable (but not absolutely essential) that the messaging software uses keep-alive or other heart-beat techniques to ensure timely detection of link or client queue manager failures. In the absence of such heart-beat technology, the servers queue manager waits a configurable (but short) time for a reply before assuming that the link or client queue manager has failed  
         [0113]     ii) if the servers queue manager  80  fails before it receives notification (success or failure) from the client&#39;s queue manager, then it can detect what has happened because of the “provisional go” record on its log (see earlier). In other words, the server&#39;s queue manager is aware that a response was sent to the client&#39;s queue manager as a result of the provisional go record.  
         [0114]     Note, the phase 2 (forward commit or abort) decision is made by the transaction coordinator and it (the coordinator) writes its decision to its log.  
         [0115]     If the log contains a “provisional go” but no phase 2 decision then the server queue manager can deduce that the transaction has not yet been forward completed, This is discovered when the server queue manager reads back its log at restart and the server queue manager then hardens a “commit possibly not notified”, and makes the forward complete decision (strictly: writes a “forward complete” phase 2 decision to its log), and tells the RMs to forward complete,  
         [0116]     If there is a phase 2 decision on the log then the server queue manager knows that the transaction has already been forward completed.  
         [0117]     To clarify, the exact sequence of the preferred embodiment is: 
    1. The coordinator {server queue manager) instructs all RMs to PREPARE     2. The coordinator receives “OK” from all the RMs     3. The coordinator writes a “provisional go” to its log (indicating that it is about to send a response to the client&#39;s queue manager)     4. The coordinator sends a response to client end and awaits confirmation from client&#39;s queue manager     5. Confirmation arrives at the coordinator who decides to “forward complete”    6. The coordinator writes the “forward complete” phase 2 decision to its log     7. The coordinator tells all RMs to forward complete.    
 
         [0125]     The RMs are in-doubt from when they do their prepare OK until they hear the coordinators final decision. Under all circumstances, when they do hear the coordinators final decision they hear the decision that has been written to the coordinators log.  
         [0126]     If the coordinator fails at steps 4 or 5 then it can&#39;t tell by looking at its log whether it sent the response (might have failed in 4) or whether the client end confirmed receipt (might have failed in 5).  
         [0127]     At this stage the coordinator is in-doubt. This is not allowed. The coordinator must therefore make a decision. It reasons thus: 
        If the client application did get the response then, the server queue manager is morally obliged to forward complete—i.e. the client application must be able to assume that if a response is received, the server application&#39;s processing WILL be finalized.     If the client application fell over then forward complete is not prohibited     So the server queue manager forward completes,        
 
         [0131]     Then to be on the safe side, a “commit possibly not notified” report is created. This is because there is a small chance that the client application is unaware that the server application actually processed its request. The report could be written to a dead letter queue or similar.  
         [0132]     At restart (assuming a response was sent), the server&#39;s queue manager  80  creates the ““commit possibly not notified” report and forward completes the transaction.  
         [0133]     Otherwise (if no “provisional go” record exists), the servers queue manager aborts the transaction.  
         [0134]     Observe that:  
         [0135]     if the client application receives its response, it can safely assume that the transaction has been (or will be) forward completed. “Safely” here is the same as with traditional distributed two-phase commit (2PC) transactionality (but does not incur the overheads of, or the risk of long in-doubts from, distributed 2PC).  
         [0136]     If the client application does not receive its response—that is, its GET for the response message fails—it can safely assume that either the transaction never started or the transaction has been (or will be) backed out.  
         [0137]     Safely” here is less safe than with traditional distributed 2PC but is essentially the same as with the “assured one time delivery” of established messaging systems—that is, exceptions are rare and handling the exception cases is not the responsibility of the client application.  
         [0138]     To be clear, the only exceptions arise when:  
         [0000]     i) The server fails after writing a “provisional go” record to its log but before sending the response message; or  
         [0139]     ii) The servers queue manager succeeds in sending the response message but the communication link fails to deliver the response message to the client application&#39;s queue manager. The chances of this happening depend on details of lower level protocols used by the link itself.  
         [0140]     The client application chooses what constitutes “a reasonable amount of time” within which to perform the requested service by specifying that time as the time-out value on the GET it issues for the response.  
         [0141]     If the client application itself tails before its GET completes then the outcome is (obviously) not known to the client application itself. Procedures for handling client application failure must take this into account.  
         [0142]     An optional component reduces the frequency of exception cases still further, This components works as follows:  
         [0143]     When the client application PUTs the request message, the client&#39;s queue manager does not transmit the request message to the server application until the client application issues its GET request for the response message. This allows the client&#39;s queue manager to respond to the server&#39;s queue manager without needing to wait for the client application&#39;s GET—i.e. the client application&#39;s GET is already waiting for the server application&#39;s response.  
         [0144]     To summarise, the present invention (in accordance with a preferred embodiment) enables the client application to safely make an assumption that a lack of response from the server application means that the client&#39;s request has not and will not be processed. The servers queue manager is able to determine when the client application has not received a response and is able to take appropriate action depending upon the state it is at with regard to processing the client application&#39;s initial request.  
         [0145]     Thus the following happens such that the server queue manager is able to determine when the client application has not received a response,  
         [0000]     i) The server&#39;s queue manager prepares the transaction. This means everyone involved (except the client application) is sure they&#39;re happy but could still abort if necessary.  
         [0000]     ii) The server&#39;s queue manger sends an “it worked” response to the client queue manager and waits until the client queue manager reports what happened.  
         [0000]     iii) If the client&#39;s queue manager reports that the client application got the message, the server queue manager tells everyone involved (except the client) to forward complete the transaction.  
         [0146]     If the client&#39;s queue manager reports the client application did not get the message, the server queue manager tells everyone involved to abort the transaction.  
         [0147]     In this way, a one phase commit resource (the client queue manager) is included as the last participant in a transaction with a two phase commit resource (i.e. the server queue managers transaction).  
         [0148]     The transmission of the response from the server queue manager to the client queue manager and the client application&#39;s GET are thus included as an additional 1PC component of the server queue manager&#39;s 2PC transaction.  
         [0149]     That is:  
         [0150]     The servers queue manager and the clients queue manager cooperate to create a novel 1PC transaction that does not exist in conventional asynchronous messaging.  
         [0151]     Further, the server&#39;s queue manager and the client&#39;s queue manager cooperate to include this novel 1PC transaction in the server&#39;s 2PC transaction.  
         [0152]     If the server queue manager does not receive a response from the client queue manager, the servers queue manager could be left waiting for a response indefinitely. Consequently some additional work is done to minimise the server queue managers time “in-doubt”.  
         [0153]     However, in the final analysis the server queue manager may need to take a guess (i.e. a heuristic outcome). In case the heuristic outcome is incorrect, this is recorded in a way analogous to the WebSphere MQ dead letter queue.  
         [0154]     Although it has been mentioned that the client application&#39;s GET of the server application&#39;s response may be a lpc resource, this does not have to be the case. The GET can be non-transactional, 1PC transactional, or 2PC transactional—the invention is equally applicable for all three of these possibilities.  
         [0155]     However, in the preferred embodiment the 2PC transaction between queue managers and the COMMIT of the client application GET—which are normally entirely separate from each other and from the server queue managers 2PC transaction—are collapsed into a novel 1PC process and then 1PC process is included into the server&#39;s 2PC transaction.  
         [0156]     It should be appreciated that while the preferred embodiment has been described specifically in terms of queue managers, the invention is not limited to such but is applicable to any communication manager.  
         [0157]     A particular advantage of the present invention is that this functionality can be provided without disruption to the client application itself.