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 » Does Topics in MQ Support Load Balancing?

Post new topic  Reply to topic
 Does Topics in MQ Support Load Balancing? « View previous topic :: View next topic » 
Author Message
schandolu
PostPosted: Fri Jan 03, 2014 6:44 am    Post subject: Does Topics in MQ Support Load Balancing? Reply with quote

Newbie

Joined: 26 Dec 2013
Posts: 9

Hi ,
i am new to WMB.As per my understanding from EMS/JMS,Topics does'nt support LOAD Balancing(i.e we cannot scale the instances at subscriber side) if multiple consumers are subscribing to it.
If we want to configure load balancing we will use queues.

Please let me know wheather this is the same case in IBM MQ?

Thanks,
Siv
Back to top
View user's profile Send private message
mqjeff
PostPosted: Fri Jan 03, 2014 7:48 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

Every subscriber gets a copy of every publication.

How is that not scalable?
Back to top
View user's profile Send private message
schandolu
PostPosted: Fri Jan 03, 2014 8:55 am    Post subject: Reply with quote

Newbie

Joined: 26 Dec 2013
Posts: 9

Can the load be distributed if there are any multiple instances of same adapter service is subscribed to the source topic.
Back to top
View user's profile Send private message
zpat
PostPosted: Fri Jan 03, 2014 9:03 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

You are asking if a given message can be given to some subscribers but not all, on a load balancing basis. Essentially no.

However if you create administrative subscription(s) which direct the messages to one or more queues, then you can have more than one listener on some or all of those queues if you like.
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Fri Jan 03, 2014 9:21 pm    Post subject: Reply with quote

Grand High Poobah

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

zpat wrote:
You are asking if a given message can be given to some subscribers but not all, on a load balancing basis. Essentially no.

However if you create administrative subscription(s) which direct the messages to one or more queues, then you can have more than one listener on some or all of those queues if you like.


Which means essentially yes, but you need to shape your subscription to dispatch the topic to a specified queue... using all the aliasing the cluster allows you too... It gets really tricky if you want the consumer to be a topic consumer but vastly easier if the consumer is a queue consumer.

You'll still see the Destination on the messages being a topic destination...
The truth is not some subscribers vs others, but essentially multiple instances of the same subscriber on different boxes.... Note that the subscription should only be done once across all instances of subscribers. Hence much easier to do with an admin type subscription...

In order to set up the topic consumption correctly you might have to create the subscription once per consumption instance and delete it administratively as a duplicate... on the producer qmgr... (not tried) having the consumer being a queue consumer however works fine...(tried)


_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
sridhsri
PostPosted: Mon Jan 06, 2014 9:13 am    Post subject: Reply with quote

Master

Joined: 19 Jun 2008
Posts: 297

I agree that explicitly creating subscriptions in MQ (with destination as a queue) is probably the best way to do it.

However, I think it is possible without doing that as well. If more than one subscribers have the same "client id" then all of subscribers will not receive a copy of the message (only one of them will). For this to work I think the subscribers have to be durable.
Back to top
View user's profile Send private message
zpat
PostPosted: Tue Jan 07, 2014 2:40 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

There are MSGDLV options, but I am not sure your statement is correct about client id, but then I have no idea what this is.

I assume it's something to do with MQSO_FIXED_USERID vs MQSO_ANY_USERID
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
sridhsri
PostPosted: Tue Jan 07, 2014 7:48 am    Post subject: Reply with quote

Master

Joined: 19 Jun 2008
Posts: 297

The notion of a client id is part of the JMS specification. It is not MQ specific. Every durable subscriber has a unique client id associated with it (if none is set by the user, then one is automatically generated).

If more than one subscribers share this client id, then only one of them will receive a subscription. We use this technique today.
Back to top
View user's profile Send private message
zpat
PostPosted: Tue Jan 07, 2014 8:36 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

Well it doesn't work that way with administrative subs. I just defined two subs from mqm user with the same dest queue and when I published a message - that queue received two copies.
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Tue Jan 07, 2014 8:40 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

zpat wrote:
Well it doesn't work that way with administrative subs. I just defined two subs from mqm user with the same dest queue and when I published a message - that queue received two copies.


You can't change the SUBID of an administrative subscription.
Back to top
View user's profile Send private message
zpat
PostPosted: Tue Jan 07, 2014 8:45 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

Sub id, as opposed to Sub User id....
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
sridhsri
PostPosted: Tue Jan 07, 2014 9:46 am    Post subject: Reply with quote

Master

Joined: 19 Jun 2008
Posts: 297

mqjeff is correct.

For this to work, you must use managed subscriptions. In the Java application you will supply the "client id".
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 » Does Topics in MQ Support Load Balancing?
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.