|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
MQ V7.0 Clustered Topics JMS |
« View previous topic :: View next topic » |
Author |
Message
|
tof |
Posted: Mon Sep 29, 2008 8:34 am Post subject: MQ V7.0 Clustered Topics JMS |
|
|
Novice
Joined: 29 Sep 2008 Posts: 14
|
Hi all,
I am trying to setup a distributed pub/sub cluster of Websphere MQ v7.0 queue managers and I'd like to use JMS and pub/sub for clients.
I am using the online material at: http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/index.jsp
but, up to now I was never able to setup communication among queue managers to that publications flow across the cluster.
I started stripping down elements from my needed experimental setting to get to a simple example (forget JMS and pub/sub for now) and could successfully run the clustering verification procedure at:
http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/index.jsp?topic=/com.ibm.mq.csqzah.doc/qc10440_.htm
In my understanding this means the queue managers are connected and talk to each other having a cluster queue (although I could only seem to read messages from one side, while sending from both).
Next step is using JMS, connecting to queue managers, creating a topic and start publishing and subscribing.
Here's the code I use:
Code: |
JmsFactoryFactory ff = JmsFactoryFactory.getInstance(JmsConstants.WMQ_PROVIDER);
MQTopicConnectionFactory factory = (MQTopicConnectionFactory) ff.createTopicConnectionFactory();
// Config
factory.setHostName("localhost");
factory.setPort(server_port);
factory.setTransportType(JMSC.MQJMS_TP_CLIENT_MQ_TCPIP);
// message selection performed by broker
factory.setMessageSelection(JMSC.MQJMS_MSEL_BROKER);
factory.setQueueManager(qmgr);
connection = (MQTopicConnection) factory.createTopicConnection();
connection.start();
session = (MQTopicSession) connection.createTopicSession(false,
Session.DUPS_OK_ACKNOWLEDGE);
topic = (MQTopic) session.createTopic("topic://mytopic"); |
I create connections and Topics from the clients, and hopefully the server will realize they're the clustered ones I adminstratively created upon starting queue managers. I get no exceptions, no errors on queue mgrs: alas publications are only received by local (i.e. same queue manager) JMS clients.
My question is: how do I get publications to flow across queue managers in the same cluster?
I saw the PUBSCOPE / SUBSCOPE properties that can be set when creating a clustered topic: how do I set them in JMS? Any time I try to use the setXPropery() methods the JMS clients die without a warning. Same thing for JMSAdmin commands, I cannot seem to find a way to create cluster topics having messages flow through the whole cluster with JMS or JMSAdmin.
In there anybody out there willing to shed some light on the matter?
Thanks in advance,
g |
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Sep 29, 2008 11:39 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Have you tried using RFHUtil ?? _________________ MQ & Broker admin |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|