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 » Sending a message to multiple destinations???

Post new topic  Reply to topic
 Sending a message to multiple destinations??? « View previous topic :: View next topic » 
Author Message
eswarnv
PostPosted: Mon Aug 26, 2002 6:37 pm    Post subject: Sending a message to multiple destinations??? Reply with quote

Voyager

Joined: 20 Dec 2001
Posts: 88

Hi

Please suggest me on the following.

1) I want to write a message flow which sends an input message to multiple destinations depending on some condition?? What node i have to use and what properties i have to set??? I want to retrieve destinations from the database???? ( Not publish/subscribe )

2) I have a message flow with simple input node and output node. For ouput node how to specify target qmanager and queue dynamically???(thru esql, not in output node properties)




Thanks and Regards
Eswar
Back to top
View user's profile Send private message
kirani
PostPosted: Mon Aug 26, 2002 6:59 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

This topic has been discussed in this forum for many times. Please do a search for DestinationList and you will find the answer.

Following is the link to one of them ..
http://www.mqseries.net/phpBB2/viewtopic.php?t=4896
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
eswarnv
PostPosted: Tue Aug 27, 2002 5:43 pm    Post subject: Reply with quote

Voyager

Joined: 20 Dec 2001
Posts: 88

Hi Kiran,

Have gone thru the link and i found the following code,

Code:
IF ( condition1) THEN
  SET OutputLocalEnvironment.Destination.MQ.DestinationData[1].queueName = 'Q1'
  SET OutputLocalEnvironment.Destination.MQ.DestinationData[1].queueManagerName = 'QMgr1';
ELSE
  SET OutputLocalEnvironment.Destination.MQ.DestinationData[1].queueName = 'Q2'
  SET OutputLocalEnvironment.Destination.MQ.DestinationData[1].queueManagerName = 'QMgr2';
END IF;


My Question:
If i write above code in a compute node, then what is the target node for Compute Node and what properties to be set for that node..

Thanks and Regards
Eswar
Back to top
View user's profile Send private message
lung
PostPosted: Tue Aug 27, 2002 6:32 pm    Post subject: Reply with quote

Master

Joined: 27 Aug 2002
Posts: 291
Location: Malaysia

The queuename and queuemanager values u set is saved in the properties of the message, so from the Compute node you can basically direct it to any other node as long as the message headers are copied over.

For the properties of the output node, just make sure you set it to DestinationList and your message will end up in the queues as defined earlier in the Compute node.
_________________
lung
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger MSN Messenger
kirani
PostPosted: Tue Aug 27, 2002 6:55 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

lung wrote:
The queuename and queuemanager values u set is saved in the properties of the message, so from the Compute node you can basically direct it to any other node as long as the message headers are copied over.


Actually, these values are stored into another tree (DestinationList/LocalEnvironment).

Eswar,
In this compute node, make sure you select "DestinationList/LocalEnvironment" as a part of Compute mode in Advanced tab. As Lung said, your MQOutput node should be configured to specify "Destination List" in advanced tab.
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
lung
PostPosted: Tue Aug 27, 2002 7:00 pm    Post subject: Reply with quote

Master

Joined: 27 Aug 2002
Posts: 291
Location: Malaysia

Thanks for the correction, Kiran

Most of the time, I just select 'All' in the Advanced tab of my Compute node.
_________________
lung
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger MSN Messenger
kirani
PostPosted: Tue Aug 27, 2002 8:56 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Lung,

This might create problems if you are setting your LocalEnvironment tree in one compute node and not copying it in further compute nodes. For example, conside this message flow:

MQInput->Compute1->Compute2->MQOutput

Let's say in Compute1 you are setting some variable in LocalEnvironment Tree using following ESQL code and you have selected "copy entire message".
Code:

SET OutputLocalEnvironment.Variables.Myvar = 'ABC';
SET OutputRoot = InputRoot;


In Compute2, you are now setting the DestinationList using esql code mentioned in my earlier post. You have also selected "Copy entire message" here, which will insert following code into your Compute2 node:
SET OutputRoot = InputRoot;

Compute mode property for above 2 nodes is set to "All". There is no problem with first compute node, but your second compute node will do some "hidden tricks"!

Since you have not modified LocalEnvironment tree in Compute2 node, but by specifying compute mode to "All" you are telling broker that you have modified the LocalEnvironment/Message tree in this node. By setting Compute mode to some value (Message, LocalEnvironment, ...) you are taking the responsibility of copying/building that particular Output tree. So in your code, if you don't have following ESQL statement, you will receive empty LocalEnvironment tree after Compute2 node.
SET OutputLocalEnvironment = InputLocalEnvironment;

To solve this problem either select "Message" in Compute mode or add above ESQL statement to your Compute2 node and keep compute mode to "All".
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
lung
PostPosted: Tue Aug 27, 2002 10:29 pm    Post subject: Reply with quote

Master

Joined: 27 Aug 2002
Posts: 291
Location: Malaysia

Hmm. Got it. Thanks!
_________________
lung
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Sending a message to multiple destinations???
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.