ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » How does WMB relate a Request with the Response?

Post new topic  Reply to topic
 How does WMB relate a Request with the Response? « View previous topic :: View next topic » 
Author Message
limal_raja
PostPosted: Fri Jan 22, 2010 4:16 am    Post subject: How does WMB relate a Request with the Response? Reply with quote

Novice

Joined: 11 Nov 2009
Posts: 19

How does WMB relate a Request with the Response?

For eg. When I send 2 requests RQ1 and RQ2 with msgId M1 and M2 respectively, when i get the responses(say RS1 and RS2) how does the system recognize if response RS1 is for request RQ1 and not for RQ2 or vice versa?
Back to top
View user's profile Send private message
mqmatt
PostPosted: Fri Jan 22, 2010 4:39 am    Post subject: Reply with quote

Grand Master

Joined: 04 Aug 2004
Posts: 1213
Location: Hursley, UK

Depends on which nodes you're using; if you're using asynchronous request nodes (e.g. SOAP or SCA), then this is managed for you.
For the general case, you need to manage the correlation identifiers yourself, using queues for example.
In V7 there is a pattern that implements request/response for you.

Regards
-Matt
Back to top
View user's profile Send private message
rajparekh08
PostPosted: Sun Jan 24, 2010 11:12 pm    Post subject: Reply with quote

Acolyte

Joined: 21 Sep 2009
Posts: 58
Location: India- Bagalore

You can use co-relation ID.
LIke you can set the message ID to co relation ID, and when you get the response, you will knw from the co - relation ID. That is, if the co-relation ID is the same as the request MsgId, then you can match them.
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
smdavies99
PostPosted: Mon Jan 25, 2010 12:06 am    Post subject: Reply with quote

Jedi Council

Joined: 10 Feb 2003
Posts: 6076
Location: Somewhere over the Rainbow this side of Never-never land.

mqmatt wrote:

In V7 there is a pattern that implements request/response for you.

Regards
-Matt


I get the impression from some of the posts here that quite a few users of this forum don't know what a pattern is and how to use them.

rajparekh08 wrote:

You can use co-relation ID.
LIke you can set the message ID to co relation ID, and when you get the response, you will knw from the co - relation ID. That is, if the co-relation ID is the same as the request MsgId, then you can match them.


It would be easier to understand in you used the proper name.
MSGID.CorrelId
is related to
MSGID.MsgId
in that in the MQOutputNode(etc) there is a flag which will copy the MQMD.MsgId to the MQMD.CorrelID before the message is returned. Swapping these is a quite common method of handling Request/Reply.
You can configure nodes to get a message by a match with MQMD.CorrelId or the MQMD.MsgId
See the MQGMO options description in th WMQ Application Programming Manual for a better description.
_________________
WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995

Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » How does WMB relate a Request with the Response?
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.