Author |
Message
|
kotla.satya |
Posted: Wed Sep 12, 2007 5:11 am Post subject: Setting Header values in Websphere MQ JMS Message |
|
|
Apprentice
Joined: 30 Jan 2006 Posts: 40 Location: chennai-India
|
HI All,
I am new to Webspher MQ JMS. I am using Websphere MQ JMS api for programming.
I have a requirement like to have APP_ID,MSG_LENGTH as a part of header.
Can you please tell me how to set header values in a JMS message and how to cross check the header values present in a message in MQ server. |
|
Back to top |
|
 |
Vitor |
Posted: Wed Sep 12, 2007 5:18 am Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
kotla.satya wrote: |
Can you please tell me how to set header values in a JMS message and how to cross check the header values present in a message in MQ server. |
Check the Using Java manual. It describes how to set JMS header properties that map onto the MQRFH2 <usr> folder, the MQ construct used to hold the JMS header while the message is in transit. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
kotla.satya |
Posted: Wed Sep 12, 2007 5:40 am Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
Apprentice
Joined: 30 Jan 2006 Posts: 40 Location: chennai-India
|
Vitor wrote: |
kotla.satya wrote: |
Can you please tell me how to set header values in a JMS message and how to cross check the header values present in a message in MQ server. |
Check the Using Java manual. It describes how to set JMS header properties that map onto the MQRFH2 <usr> folder, the MQ construct used to hold the JMS header while the message is in transit. |
Thank you for the prompt reply.
I see in the manual a jms property 'JMSXAppID', the MQMD field retreived from is given as PutApplName and it is blank in MQRFH2 field retrieved from. When i am setting message.setStringProperty("JMSXAppID","AM_PMDDER") ,
I am getting an exception as below
javax.jms.MessageFormatException: MQJMS1058: Invalid message property name: JMSXAppID.
Please correct me ,if the approach is correct.
I see in the manual MQRFH2 mappings for JMS headers,but frankly speaking I have no idea about MQRFH2.
I am not aware of the MQRFH2 <usr> folder, can you please tell me what could be the path of the folder.
Thanks in advance |
|
Back to top |
|
 |
Vitor |
Posted: Wed Sep 12, 2007 5:48 am Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
kotla.satya wrote: |
I see in the manual a jms property 'JMSXAppID', the MQMD field retreived from is given as PutApplName and it is blank in MQRFH2 field retrieved from. When i am setting message.setStringProperty("JMSXAppID","AM_PMDDER") ,
I am getting an exception as below
javax.jms.MessageFormatException: MQJMS1058: Invalid message property name: JMSXAppID.
Please correct me ,if the approach is correct. |
Not a Java person but I think that's a read only value holding the id of the application that put the message.
kotla.satya wrote: |
I see in the manual MQRFH2 mappings for JMS headers,but frankly speaking I have no idea about MQRFH2.
I am not aware of the MQRFH2 <usr> folder, can you please tell me what could be the path of the folder. |
Any values you like (within reason). The Using Java manual describes how the JMS header is mapped onto the MQ headers, and the Application Programming Guide / Reference describes the fields & folders of the RFH2. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
kotla.satya |
Posted: Wed Sep 12, 2007 6:02 am Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
Apprentice
Joined: 30 Jan 2006 Posts: 40 Location: chennai-India
|
kotla.satya wrote: |
I see in the manual MQRFH2 mappings for JMS headers,but frankly speaking I have no idea about MQRFH2.
I am not aware of the MQRFH2 <usr> folder, can you please tell me what could be the path of the folder
Any values you like (within reason). The Using Java manual describes how the JMS header is mapped onto the MQ headers, and the Application Programming Guide / Reference describes the fields & folders of the RFH2. |
Can you please tell me the links to get the manuals/guides, as the UsingJAVA.pdf I have is not that much clear to understand. If it is possible to post the attachments can you please post them.
Sorry for the inconvinience.
Thank you in advance |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed Sep 12, 2007 6:12 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Where have you looked for this information? _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
Vitor |
Posted: Wed Sep 12, 2007 6:29 am Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
kotla.satya wrote: |
[Can you please tell me the links to get the manuals/guides, as the UsingJAVA.pdf I have is not that much clear to understand. |
All are available from the IBM website MQ Library, where I suspect your UsingJava.pdf was sourced from. The APG & APR are available in the same format, or as an online HTML resource which is the same text but is provided for those people who prefer HTML.
(I don't - I like manuals in files. I always encounter problems when I've no connection to the Internet. But that's just my view and I know many don't share it)
The online link is on the same page as the PDFs. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed Sep 12, 2007 6:31 am Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Vitor wrote: |
I've no connection to the Internet. |
I know all of these words, but I do not understand them when put together that way...
 _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
kotla.satya |
Posted: Wed Sep 12, 2007 7:08 pm Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
Apprentice
Joined: 30 Jan 2006 Posts: 40 Location: chennai-India
|
Vitor wrote: |
kotla.satya wrote: |
[Can you please tell me the links to get the manuals/guides, as the UsingJAVA.pdf I have is not that much clear to understand. |
All are available from the IBM website MQ Library, where I suspect your UsingJava.pdf was sourced from. The APG & APR are available in the same format, or as an online HTML resource which is the same text but is provided for those people who prefer HTML.
The online link is on the same page as the PDFs. |
I have got the pdf's from one of my friend, I am not aware from where he has taken it.
If you could,can you please send me the url .
Thank you very much. |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed Sep 12, 2007 8:00 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Where have you looked for this information? _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
kotla.satya |
Posted: Wed Sep 12, 2007 10:31 pm Post subject: |
|
|
Apprentice
Joined: 30 Jan 2006 Posts: 40 Location: chennai-India
|
jefflowrey wrote: |
Where have you looked for this information? |
I have a pdf named UsingJava.pdf, in that I am looking in to
Chaper 12 Jms Messages,in that I am seeing 'Mapping JMS messages onto WebSphere MQ messages' topic.
I think that answers your question, if not can you please send me the url of website for getting usingjava manual and application programming ref. guide.
Thank you very much for the prompt replies. |
|
Back to top |
|
 |
Vitor |
Posted: Wed Sep 12, 2007 11:10 pm Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
kotla.satya wrote: |
If you could,can you please send me the url .
|
www.ibm.com
 _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
kotla.satya |
Posted: Wed Sep 12, 2007 11:22 pm Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
Apprentice
Joined: 30 Jan 2006 Posts: 40 Location: chennai-India
|
Vitor wrote: |
kotla.satya wrote: |
If you could,can you please send me the url .
|
www.ibm.com
 |
I will be very much thankful to you,if you could give me exact url.
Thanks in advance |
|
Back to top |
|
 |
Vitor |
Posted: Wed Sep 12, 2007 11:41 pm Post subject: Re: Setting Header values in Websphere MQ JMS Message |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
kotla.satya wrote: |
I will be very much thankful to you,if you could give me exact url. |
I will be very much thankful if you could use the site search facility that IBM have built, or at least read my previous posts:
Vitor wrote: |
All are available from the IBM website MQ Library |
But if you're too busy to read posts, ask your friend, search the IBM site or even this forum (where it's been quoted pretty frequently) then so be it:
http://www-306.ibm.com/software/integration/wmq/library/library6x.html
Hope you find time to read them in your busy life. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
|