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 » Multiple MQ Clients connectivty issue to single Queue Mgr

Post new topic  Reply to topic
 Multiple MQ Clients connectivty issue to single Queue Mgr « View previous topic :: View next topic » 
Author Message
sunnybab
PostPosted: Tue May 23, 2006 8:18 pm    Post subject: Multiple MQ Clients connectivty issue to single Queue Mgr Reply with quote

Novice

Joined: 12 Jan 2006
Posts: 21

Hi all,

I have MQ 6.0 and WAS 5.1 setup .. There are two Solaris App Servers ( app1 and app2 ) running WAS 5.1 and MQ 6.0 Client.
and third Solaris system ( MQ1) running MQ 6.0 Server with Queue manager /Listener and queues defined .

MQ Listener is enabled on both Client systems ( App1 and App2) .

This Setup works fine as long as I have one AppServer either ( App1 or App2) running.

As soon as I start the second server it throws below exception :

J2CA0056I: The Connection Manager received a fatal connection error from the Resource Adaptor for resource JMSQueueConnectionFactory. The exception which was received is javax.jms.JMSException: MQJMS2008: failed to open MQ queue

since both App1 and App2 are trying to connect to same System ( MQ1) QM /Queues and Pick up the message from there..

JMS queue Connection factory and MQ Queue Destinations are defined in CLIENT mode on ( app1 and app2) to point to MQ1 QM and queues .

Any ideas on how to configure so both client machines ( app1 and app2) can pick up the messages from MQ1 system ?

Thanks in advance
sunny
Back to top
View user's profile Send private message
8davitt
PostPosted: Tue May 23, 2006 11:21 pm    Post subject: Reply with quote

Apprentice

Joined: 06 Feb 2003
Posts: 37
Location: Seated in front of monitor

Ensure that you are using Enable Clone Support associated with your Connection Factory definitions.

Refer to

http://publib.boulder.ibm.com/infocenter/wasinfo/v5r1//index.jsp?topic=/com.ibm.websphere.base.doc/info/aes/ae/umj_ptcfw.html

/s
Back to top
View user's profile Send private message
Pieper
PostPosted: Thu May 25, 2006 2:28 am    Post subject: Reply with quote

Newbie

Joined: 25 May 2006
Posts: 4

8davitt wrote:
Ensure that you are using Enable Clone Support associated with your Connection Factory definitions.

Refer to

http://publib.boulder.ibm.com/infocenter/wasinfo/v5r1//index.jsp?topic=/com.ibm.websphere.base.doc/info/aes/ae/umj_ptcfw.html

/s


Hi,

I have the same question. This "cloning" is only a feature for topics, isn't it? I think the question was about receiving messages by two queue listeners. (round-robin mechanism or similar)

Each messages should only by delivered to one client, but in a load-balacing fasion.

Pieper
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu May 25, 2006 2:55 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

There is no load balancing that way. It is a first come first serve. What you need is to ensure that the queue is not opened in exclusive mode and have 2 or more consumers active on the queue.

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Pieper
PostPosted: Thu May 25, 2006 3:09 am    Post subject: Reply with quote

Newbie

Joined: 25 May 2006
Posts: 4

fjb_saper wrote:
There is no load balancing that way. It is a first come first serve. What you need is to ensure that the queue is not opened in exclusive mode and have 2 or more consumers active on the queue.

Enjoy


Yes, load-balancing was wrong. My main intention is to have a resilience feature.

How can I ensure via JMS that the queue is not opened exclusive?

I want to connect two Spring 2.0 MessageListener POJOs with onMessage() methods to the queue. In this case I have two consumer, haven't I?

Thanks in advance

Pieper
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu May 25, 2006 3:15 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Part of it is in the MQ setup. Part of it is in the JMS setup.
You need to make sure in each case that you do not have any process that is opening the queue in exclusive mode. This includes any other process accessing the queue (non JMS or here involved process as well).

Then you define on each box / app server an MDB and you should be doing fine. Make sure that each appserver is using its own QueueConnectionFactory.

Enjoy

[addendum]The JMS part of the setup is in the setup of the queue as a javax.jms.Destination. There are a number of properties passed when you set up the queue in JNDI. Here you specify as well the default type of access.
Hint -- do not leave the access as default but make it explicit. Make sure it is defined as shared --. To achieve greater throughput when the order of consumption is not important you can set up the MDB to have multiple instances in the appserver.[/addendum]
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Pieper
PostPosted: Thu May 25, 2006 8:48 am    Post subject: Reply with quote

Newbie

Joined: 25 May 2006
Posts: 4

Thanks for your advice.

Two questions are still open:

- which JMS properties for Websphere MQ do I have to set?
- I am not using MDBs in an appserver, but standalone MDBs as a feature of Spring Framework 2.0. Does your answers also apply to that?


Pieper
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Thu May 25, 2006 9:06 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Pieper wrote:
- which JMS properties for Websphere MQ do I have to set?

The ones that control the open mode of the Queue Connection.

Pieper wrote:
- I am not using MDBs in an appserver, but standalone MDBs as a feature of Spring Framework 2.0. Does your answers also apply to that?


I'll skip my usual rant about using J2EE components outside a J2EE container.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Pieper
PostPosted: Thu May 25, 2006 9:10 am    Post subject: Reply with quote

Newbie

Joined: 25 May 2006
Posts: 4

jefflowrey wrote:
Pieper wrote:
- which JMS properties for Websphere MQ do I have to set?


The ones that control the open mode of the Queue Connection.

Are you aware of the name of the property?

Thanks,
Pieper
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Thu May 25, 2006 9:23 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Pieper wrote:
Are you aware of the name of the property?


Yes, I'm aware of the name of the property.

Or at least, I'm aware that it's one of the one's listed at http://publib.boulder.ibm.com/infocenter/wmqv6/v6r0/index.jsp?topic=/com.ibm.mq.csqzaw.doc/jms77h3.htm


_________________
I am *not* the model of the modern major general.
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 » IBM MQ Java / JMS » Multiple MQ Clients connectivty issue to single Queue Mgr
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.