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 » IBM MQ Java / JMS » Client channel definition table in Java

Post new topic  Reply to topic
 Client channel definition table in Java « View previous topic :: View next topic » 
Author Message
vasu
PostPosted: Wed Jan 23, 2002 4:03 pm    Post subject: Reply with quote

Novice

Joined: 13 Nov 2001
Posts: 15

Hi MQ Gurus,

Can I use a client channel definition table for MQSeries Java Client API. My requirement is, I have two MQ Servers with same QMgr & Queue definitions. My application should connect to Server2 if server1 is not available. I heard, for C++ API, you can create a Channel definition table and set that in MQ Environment variables (MQCHLLIB, MQCHLTAB). Will this approach work for Java ? If not, can you please suggest the best way to do this ? Don't tell me I have to handle it myself in my application

Thanks,
Vasu.

Back to top
View user's profile Send private message Send e-mail
kolban
PostPosted: Thu Jan 24, 2002 7:20 am    Post subject: Reply with quote

Grand Master

Joined: 22 May 2001
Posts: 1072
Location: Fort Worth, TX, USA

You have to handle it in your application

But seriously, in Java, this is a trivial task. Create a proerties file and write a trivial Java class that contains a HashTable, reads the properties file and then SuperClass MQQueueManager to map the queue manager name supplied to the MQEnvironment settings found in the HashTable.
Back to top
View user's profile Send private message
vasu
PostPosted: Thu Jan 24, 2002 7:49 am    Post subject: Reply with quote

Novice

Joined: 13 Nov 2001
Posts: 15

Hi Kolban,

Thanks for your reply & suggestion. Hey, I have one more question. In my Java application, is it a good idea to cache MQ Connections and reuse them, or is it a best practice to establish connection every time I need to send a message ? We are using MQ JMS API.

Thanks,
Vasu.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » Client channel definition table in Java
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.