Author |
Message
|
xerex |
Posted: Thu Jul 20, 2006 12:09 pm Post subject: How to control messageid generation |
|
|
Newbie
Joined: 20 Jul 2006 Posts: 1
|
In our application we want our message to retain the MessageID what ever we are generating instead of taking the MessageID generated by Websphere MQ. Currently MQ is overwriting our msgid. Is it possible to control it. Please let me know, its very imp for our application. |
|
Back to top |
|
 |
mvic |
Posted: Thu Jul 20, 2006 12:15 pm Post subject: Re: How to control messageid generation |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
xerex wrote: |
In our application we want our message to retain the MessageID what ever we are generating instead of taking the MessageID generated by Websphere MQ. |
Search the manuals for MQPMO_NEW_MSG_ID |
|
Back to top |
|
 |
wschutz |
Posted: Thu Jul 20, 2006 12:27 pm Post subject: Re: How to control messageid generation |
|
|
 Jedi Knight
Joined: 02 Jun 2005 Posts: 3316 Location: IBM (retired)
|
mvic wrote: |
xerex wrote: |
In our application we want our message to retain the MessageID what ever we are generating instead of taking the MessageID generated by Websphere MQ. |
Search the manuals for MQPMO_NEW_MSG_ID |
Does that also work for JMS? xerex didn't specify whether its base or jms classes.... _________________ -wayne |
|
Back to top |
|
 |
mvic |
Posted: Thu Jul 20, 2006 12:47 pm Post subject: Re: How to control messageid generation |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
wschutz wrote: |
Does that also work for JMS? xerex didn't specify whether its base or jms classes.... |
I see a JMSMessage.setJMSMessageID() method. The Using Java manual says, under the description for this method: "Any value set using this method is ignored when the message is sent, but this method can be used to change the value in a received message."
So I think the answer to your question is probably "no".
But I think fuller control should be possible when using the base MQ Java classes. |
|
Back to top |
|
 |
fjb_saper |
Posted: Thu Jul 20, 2006 1:29 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
And I wonder if just using the correlId would be sufficient to cater to his needs.
He did not say why he wanted to keep the msgId set by his app or what for...  _________________ MQ & Broker admin |
|
Back to top |
|
 |
jsasvari |
Posted: Fri Jul 28, 2006 1:23 pm Post subject: Re: How to control messageid generation |
|
|
Newbie
Joined: 17 Nov 2003 Posts: 1 Location: Toronto
|
xerex wrote: |
In our application we want our message to retain the MessageID what ever we are generating instead of taking the MessageID generated by Websphere MQ. |
This also means you will have to generate and manage the uniqueness of these MessageIDs. Why have the application do this when the queue manager can do the job out of the box? Do you want to control which specific GroupIDs the consumer should process? |
|
Back to top |
|
 |
|