Posted By:
Gautam_Marwaha
Posted On:
Thursday, July 18, 2002 09:51 PM
For the functionality you require, it may not be necessary to pass anything to the server.
The server can listen to a known queue, say Q. A client can create a TemporaryQueue (say q), create a message to be sent to the queue Q (on which server is the consumer), set the message.setJMSReplyTo(q) before sending out the message over Q. The server will receive this message from Q, will call message.getJMSReplyTo() to obtain the destination (which will be q) over which it will now start conversation with the client. Also, if reqd, the server can send message over the temp queue q by setting the correlationID with the value of the JMSMessageID of the client't message which will allow the client to know what message the server is replying to.