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 » WMQI Broker Name

Post new topic  Reply to topic
 WMQI Broker Name « View previous topic :: View next topic » 
Author Message
DaveBoynton
PostPosted: Wed Jun 18, 2003 7:37 am    Post subject: WMQI Broker Name Reply with quote

Newbie

Joined: 18 Jun 2003
Posts: 1
Location: London

Hi,
Does anyone know if there's a way that a message flow can derive the name of the broker it's running under? We have 4 boxes running in an MQ cluster, and the flows log entries to a single Oracle database. We need to log which broker/box the message has passed through.

I am told that the IA06 (get environment variables) plug in is no longer supported on Solaris, and this would have been one way of getting the information. We can't hard-code a value, as the code must be unchanged when promoting between environments.

Cheers,
Dave.
Back to top
View user's profile Send private message
Craig B
PostPosted: Wed Jun 18, 2003 9:12 am    Post subject: Reply with quote

Partisan

Joined: 18 Jun 2003
Posts: 316
Location: UK

Hi,

As far as I am aware, there are no "built-in" functions available to a message flow to retrieve such things as broker name, execution group name or queue manager name etc. The Plugin Programming interface has a cniGetBrokerInfo method which can retrieve such information as the broker name and message flow name etc. Therefore one option is to write a plugin node to do this retrieve these details and populate them into your output message.
_________________
Regards
Craig
Back to top
View user's profile Send private message
philip.baker
PostPosted: Wed Jun 18, 2003 2:56 pm    Post subject: Reply with quote

Voyager

Joined: 21 Mar 2002
Posts: 77
Location: Baker Systems Consulting, Inc. - Tampa

Dave,

One way I have done this in the past is to store the info in a database table on the Broker server. The message flow would query the data and use the returned data however is needed. The message flow does not have to be changed when migrating from one environment to another(accessing one database or another), it simply queries different data in whatever database it now attaches to. (There is an assumption that the database connect string (DSN/ODBC connection) is the same for the different Broker servers so the flow does not need to be changed for the database connection.)
_________________
Regards,
Phil
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
Ian
PostPosted: Thu Jun 19, 2003 2:18 am    Post subject: Reply with quote

Disciple

Joined: 22 Nov 2002
Posts: 152
Location: London, UK

Hi,

There are no WMQI functions to get the broker name.

To get the broker name you would need to write a plugin node.

C plugin :

Read the WMQIv2.1 Programming Guide manual.

cniGetBrokerInfo queries the current broker environment (for example, for information about broker
name and message flow name). The information is returned in a structure of type CNI_BROKER_INFO_ST.

Java plugin :

The following method returns the name of the broker :

getBroker().getName();

This is discussed in the following thread :
http://www.mqseries.net/phpBB/viewtopic.php?t=8349&highlight=broker+name

The Java Plugin node API is installed as part of the product.
For example : C:\Program Files\IBM\WebSphere MQ Integrator 2.1\docs\JavaAPI\index.html
_________________
Regards, Ian
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 » WMQI Broker Name
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.