I am trying to send reply Q details in the JMS Header when using Outbound Gateway in spring integration. I learnt that enhances made in JIRA #INT-97 copies the spring message headers to JMS headers before sending it to the JMS destination.
Before sending the message to the outbound gateway, set the message header as below. message.getHeader().setAttribute(JmsTargetAdapter.JMS_REPLY_TO, myReplyDestination);
But I am not able to find the JmsTargetAdapter class in any of the SI jars.
Can anybody help me out with the jar that has this class?
Also, Is my below understanding correct?
- Enrich your message header with the JMSReplyTo attribute which has an MQQueue object (I'm sending messages to MQ)
- Post the message using outbound gateway (by default, the JMS Headers will be appended with the SI headers)
EDIT:
I have source and destination systems where source sends request to a MQ broker eg: MQBroker 1 and destination sends back the reply to MQBroker 2. Both the brokers are interconnected through middleware layer.
I need to pass the reply Q and Q Manager details in the request header for the destination to put back the reply. But the reply Q details are residing in Broker 2 whereas the outbound gateway configs will have the Broker 1 configuration.
How to achieve this with Outbound gateway? Is this possible?