Trying to figure out the camel/Spring configuration to set ApplicationIdData using JMS.
I know the java way to do it as below, I set MQOO_SET_IDENTITY_CONTEXT using bel
All I needed to find a way in camel config to set some properties in the destination and set some header. I set destination in the header as
Note: Setting mdWriteEnabled=true is equal to
// Enable MQMD write
dest.setBooleanProperty(WMQConstants.WMQ_MQMD_WRITE_ENABLED, true);
Setting mdMessageContext=1 is equal to
// Optionally, set a message context if applicable for this MD field
dest.setIntProperty(WMQConstants.WMQ_MQMD_MESSAGE_CONTEXT,
WMQConstants.WMQ_MDCTX_SET_IDENTITY_CONTEXT);
Then set ApplicationIdData as
Complete code:
queue:///Q_Name?targetClient=1&mdWriteEnabled=true&mdMessageContext=1
true
2
APP_ID_NAME
APP_ID_NAME
I am not sure that JMS_IBM_MQMD_ApplOriginData is required.