|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Accessing the same queue |
« View previous topic :: View next topic » |
Author |
Message
|
sayan |
Posted: Mon Mar 17, 2008 2:48 am Post subject: Accessing the same queue |
|
|
Novice
Joined: 22 Feb 2008 Posts: 13
|
Hi,
I have two programs working on the same queue. One of them is putting messages and the other "GETS" it.
I am sending the mesages as "request" and populating the replytoq and replytoqmgr fields.
I am accepting the replytoq name from the user.
The problem i am facing is suppose i change the name in replytoq field, the program which browses that q fails to remove the message from the queue.
However if I restart the program which is fetching the messages the message gets processed and is removed from the Q.
I haven't used in share/exclusive mode during opening. Does it default it to exclusive?
I am not able to find out the reason. Any help will be appreciated. Thnx in advance. |
|
Back to top |
|
 |
zpat |
Posted: Mon Mar 17, 2008 3:09 am Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
Sounds like the getting program is using a single unit of work covering the MQGET and the MQPUT, then the MQPUT is failing because of an invalid replytoq, and the entire UoW is rolled back.
Check the backout count of the request message that is not removed from the queue. Check the application log for MQRC codes.
Share/Exclusive default depends on the queue definition, it only applies to input mode anyway. It's much better to use separate request and reply queues.
Retrieve reply messages by correlid, set the corelid from the messageid in the responding application. This will allow multiple requestors if needed in the future.
Last edited by zpat on Mon Mar 17, 2008 3:42 am; edited 1 time in total |
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Mar 17, 2008 3:39 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
zpat wrote: |
set the corelid from the messageid in the responding application |
Make that according to the message options (msgid to correlid or correlid to correlid)...
The default we use in JMS is to check if the correlid is initial (mqic_none). In that case we pass the messageid otherwise the correlid...
Enjoy  _________________ MQ & Broker admin |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|