Integration Server 10.11 | JMS Client Development Guide | Sending and Receiving JMS Messages | Sending a JMS Message and Waiting for a Reply
 
Sending a JMS Message and Waiting for a Reply
 
How to Send a Request Message and Wait for a Reply
How to Send a Request that Uses a Dedicated Listener to Retrieve Replies
How to Send a JMS Message and Specify a Reply Destination without Waiting for a Reply
Integration Server provides the pub.jms:sendAndWait service, which you can use to send a message and wait for a reply.
You can use the pub.jms:sendAndWait service to issue a request/reply in a synchronous or asynchronous manner.
*In a synchronous request/reply, the service that sends the request stops executing while it waits for a reply. When the service receives a reply message, the service resumes execution. If the timeout elapses before the service receives a reply, Integration Server ends the request, and the service returns a null message that indicates that the request timed out. Integration Server then executes the next step in the flow service.
*In an asynchronous request/reply, the service that sends the request continues executing the steps in the service after sending the message. To retrieve the reply, the requesting flow service must invoke the pub.jms:waitForReply service. If the timeout elapses before the pub.jms:waitForReply service receives a reply, the pub.jms:waitForReply service returns a null document indicating that the request timed out.
A service that contains multiple asynchronous send and wait invocations allows the service to send all the requests before collecting the replies. This approach can be more efficient than sending a request, waiting for a reply, and then sending the next request.