Author |
Message
|
thejavapill |
Posted: Fri Mar 10, 2006 2:14 pm Post subject: JMS - Cluster - Messaging ! |
|
|
Newbie
Joined: 24 Jan 2006 Posts: 7 Location: Ca
|
Hello,
I have the following setup in a cluster
a) Two Queue Managers on the same host (Windows), QM1 (running on port p1) and QM2 (port p2)
b) The above are in a cluster called TESTCLUSTER
c) For QM1 there is a Cluster Sender Channel called CLUS_CH_SDR_QM2 and a Cluster Receiver Channel called CLUS_CH_RECV_QM1
d) For QM2 there is a cluster sender channel called CLUS_CH_SDR_QM1 and a Cluster Receiver Channel CLUS_CH_RECV_QM2
e) One local queue on QM1 that is shared in the cluster TESTCLUSTER , since the application would send messages one way for now.
My application is Java-JMS based and I'm using JMSAdmin tool to define the admin objects. My JMS config is for the Sender QCF points to "QM1" with transport as "client" and channel as "CLUS_CH_SDR_QM2" host = localhost, port p1 and receiver QCF points to "QM2" with transport as "Client" and channel as "CLUS_CH_RECV_QM2" host = localhost, port p2.
The issue is my application cannot send a message, the exception is "Error Code:MQJMS2005:Linked Exception:com.ibm.mq.MQException: MQJE001: Completion Code 2, Reason 2009:cause:Unable to create a connection to the queue manager". My Queue Managers, Channels are running. Am I doing something wrong with the JMS Admin objects or in setting up the cluster ?
Any help is sincerely appreciated.
Thanks |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Mar 10, 2006 2:22 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You're using the wrong kind of channel for your client connection.
There is an entire manual devoted to clients. And it's even named "Clients".
Good Luck! _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
thejavapill |
Posted: Fri Mar 10, 2006 3:24 pm Post subject: |
|
|
Newbie
Joined: 24 Jan 2006 Posts: 7 Location: Ca
|
I checked the Websphere MQ Clients manual - it does not mention anything about a cluster so does this mean that a JMS program using Websphere MQ Client cannot connect to Queue managers in a cluster ? I don't think what you are saying is true. Servers dictate how clients should connect to them not vice versa.
I could connect to these queue managers when they were not shared in a cluster with the "client" transport type via JMS. Anyway I changed the transport type to "BIND" and I still have the same problem. Why ?
Thanks, |
|
Back to top |
|
 |
thejavapill |
Posted: Fri Mar 10, 2006 4:35 pm Post subject: |
|
|
Newbie
Joined: 24 Jan 2006 Posts: 7 Location: Ca
|
In order for two queue managers to communicate in a clustered environment (QM1 and QM2 assuming that messages have to travel from QM1 to QM2 one way) is the following is all that is needed ?
a) A Cluster Sender Channel on QM1 and a Cluster Receiver Channel on QM2.
b) A local queue on QM1 shared in the same cluster that has QM1 and QM2.
Thanks |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Mar 10, 2006 4:52 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Your application does not connect to the cluster.
Ever.
It always and only connects to a queue manager.
You always and only ever use one type of channel to create a client connection to that queue manager.
It is never ever ever a cluster channel.
Whether or not a queue manager is in a cluster has absolutely nothing to do with whether or not your application establishes a client connection or a server connection.
You need to start your MQ learning over, completely.
You have failed to understand the basics.
I suggest you go read the MQ Primer support pack again. And then read the Application Programming Guide. And then read the Clients manual. And then read the Intercommunications Manual. And then read the WebSphere MQ Clusters manual.
And then you can go back and read my first post in this thread again.
And then you can disagree with me intelligently, instead of idiotically. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
fjb_saper |
Posted: Sat Mar 11, 2006 5:14 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
And read up as well on the intercommunication manual as you will have to setup a cluster alias ==> just another qmgr alias.
JMS takes the non filled qmgr in the queue definitions and fills it with the one you are connected to, hence the use of an alias.( "queue:///myqueue" vs "queue://alias/myqueue")
Enjoy  _________________ MQ & Broker admin |
|
Back to top |
|
 |
|