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 » getBroker name

Post new topic  Reply to topic
 getBroker name « View previous topic :: View next topic » 
Author Message
sudeepm
PostPosted: Fri Mar 07, 2008 2:07 am    Post subject: getBroker name Reply with quote

Acolyte

Joined: 31 Jan 2008
Posts: 57

i am trying to get broker name and message flow name using java compute.

my code is

public static void getMsgBrokerName() throws MbException

{
MbNode mbnode = new MbNode();
g_brkname = mbnode.getBroker().getName();
g_messageFlow=mbnode.getMessageFlow().getName();

}


both g_brkname and g_messageFlow are static variables.

and am calling this function using classname.getMsgBrokerName();

but i get an error as soon as it reaches at line
MbNode mbnode = new MbNode();

it gives Instantiation error.

can somebody tell me what is the error here
Back to top
View user's profile Send private message
AkankshA
PostPosted: Fri Mar 07, 2008 2:15 am    Post subject: Reply with quote

Grand Master

Joined: 12 Jan 2006
Posts: 1494
Location: Singapore

well.. not sure about JCN and java its not my flavor u see

but i don see the need of initialization Mbnode etc.. just assignment shall work... String messageBrokerName = getBroker().getName();


u can get the broker name in eSQl by just one statement

SET brokername1 = BrokerName
_________________
Cheers
Back to top
View user's profile Send private message Visit poster's website
sudeepm
PostPosted: Fri Mar 07, 2008 2:42 am    Post subject: Reply with quote

Acolyte

Joined: 31 Jan 2008
Posts: 57

Thanks alot ..it worked
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 » getBroker 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.