This week's book giveaway is in the OCAJP forum.
We're giving away four copies of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) and have Khalid A Mughal & Rolf W Rasmussen on-line!
See this thread for details.
Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JMS header question

 
vivien siu
Ranch Hand
Posts: 143
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi guys,

can somebody tell me how can I add a user-defined value, say Versionid in the JMS Mmessage header? this will be sent back to a non-JMS MQ.

is it something like this?:

new MQQueue().setTargetClient(JMSC.MQJMS_CLIENT_NONJMS_MQ);
msg.setString Property("Versionid", "V1.0");
[ June 08, 2006: Message edited by: vivien siu ]
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'll move this question to the EJB/J2EE forum, where JMS is discussed.
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have got it right.
 
vivien siu
Ranch Hand
Posts: 143
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if the msg object is of class TextMessage, it will still work right?
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by vivien siu:
if the msg object is of class TextMessage, it will still work right?


It works for all message types.
 
vivien siu
Ranch Hand
Posts: 143
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok, thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic