Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Set JMSX properties in TextMessage using MQ  RSS feed

 
Sam Gehouse
Ranch Hand
Posts: 281
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is it possible to call setter on the the properties that start with JMSX.

For example, properties like JMSXUserID, JMSXAppID, JMSXDeliveryCount cannot be set.

I have a need to seting an additional property on a read only message that comes from clinet. In order to do that, I have to first clear out all the properties, put them back and add new property.

I can set all the properties back into the message other than the ones that start with JMSX.

theMsg.setStringProperty("JMSXUserID","xxx");
theMsg.setStringProperty("JMSXAppID","yyy");
theMsg.setStringProperty("JMSXDeliveryCount","1");

All the lines above throw Exception:

javax.jms.MessageFormatException: MQJMS1058: Invalid message property name: JMSXUserID

or,

javax.jms.MessageFormatException: MQJMS1058: Invalid message property name: JMSXAppID

or,

javax.jms.MessageFormatException: MQJMS1058: Invalid message property name: JMSXDeliveryCount

Are JMSX reserved so that they can NOT be set?
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!