...
To co-relate request and response JMS messages, the ESB uses a JMS correlation ID internally. For more information, refer to section http://www.eaipatterns.com/RequestReplyJmsExample.html.
Since this is a two-way invocation, the inSequence does not have the following configuration : <property action="set" name="OUT_ONLY" value="true"/>.
Response The response queue name is defined using transport.jms.ReplyDestination parameter in the JMS connection URL.
JMS Synchronous Invocations : Quad Channel JMS-to-JMS
Diagram 5 : Quad-channel JMS synchronous invocations
The following example code shows configuration of WSO2 ESB for quad-channel JMS synchronous invocations.
Code Block | ||||
---|---|---|---|---|
| ||||
<proxy name="QuadJMS" transports="jms"> <target> <inSequence> <property action="set" name="transport.jms.ContentTypeProperty" value="Content-Type" scope="axis2"/> <send> <endpoint> <address uri="jms:/BEReq?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory& java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61616&transport.jms.DestinationType=queue&transport.jms.ReplyDestination=BERes"/> </endpoint> </send> </inSequence> <outSequence> <send/> </outSequence> <target> <parameter name="transport.jms.Destination">ClientReq</parameter> </proxy> |