|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Alias to more than one Queue |
« View previous topic :: View next topic » |
Author |
Message
|
MichaelBulla |
Posted: Thu Oct 05, 2006 7:32 am Post subject: Alias to more than one Queue |
|
|
Apprentice
Joined: 27 Sep 2006 Posts: 31 Location: Hamburg/Germany
|
Hi,
I'm writing an Server-Client Application with MQ. The server has an own queue and every client has an own queue, too. The cients send messages to the server's queue. The server sends messages to the clients's queues.
But sometimes the server needs to send a broadcast. So I would like to create a queue in MQ, that publishes a message to all client-queues. So the server could just send a message, that has to be broadcasted, to this queue. This sounds like I had to use a Publish/ Subscriber Broker.
But after a half of day reading IBM Redbooks and Infocenter I know everything about the fundamentals of publish- subscriber Brokers and I am depressed and aggressive. But I still dont know how to realize this 'broadcast-queue' in MQ.
Is there a stupid simple way to do that?
Best regards Michael |
|
Back to top |
|
 |
Vitor |
Posted: Thu Oct 05, 2006 7:41 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Yep, Publish / Subscribe
Or look up namelists. Depends how dynamic your list of queues is. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
bruce2359 |
Posted: Thu Oct 05, 2006 1:01 pm Post subject: |
|
|
Guest
|
If you already have Pub/Sub, you can work with that product. If not, take a look at Distribution Lists in MQ.
A Distribution List is a set of Object Names (queuenames) and Object Queue Manager Names created by an application programmer.
The programmer MQOPENs the list; then does a single MQPUT to the list. The qmgr opens each queue/queuemanager name from the list in turn, and MQPUTs a single copy of the application data component of the message.
Again, a Dist List is a programmer construct. |
|
Back to top |
|
 |
MichaelBulla |
Posted: Fri Oct 06, 2006 12:11 am Post subject: |
|
|
Apprentice
Joined: 27 Sep 2006 Posts: 31 Location: Hamburg/Germany
|
I think pub/sub would be the cleanest way.
Has anyone an example for me? Until now I found out, that I can use JMS, AMI and PCF to do it. But no exampel how to do it.
JMS and AMI seem to need a lot of initialisation work in MQ. My target is to develop an application that automated configures a new installed MQ, so that it can be used by the actual application. So I need a solution that dont need a lot of prework in MQ.
So maybe PCF would be the easiest way? I just want to create a hard-wired connection from one queue to several other queues on the same manager. Rarely it may happen, that a new Client registers and I have to wire to an new queue.
It cant be so complicated. Please, any example?
Best regards Michael
P.S. Im using MQ 6, so no pub/sub broker needs to be installed |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Oct 06, 2006 1:41 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You can't "hardwire" anything with Pub/Sub. Pub/Sub is always dynamically driven. Applications can create durable subscriptions, and if you're using WMB as your broker, they can create retained publications, but it's still always predetermined.
In your case, you really want to use a distribution list where the list is read from a property file of some kind.
PCF messages are only good for configuring MQ, you can't do Pub/Sub or distribution lists with them.
You should keep the configuration part separate from your actual business application. Put it in an installer, or simply provide one or more MQSC scripts that can be run against some queue manager. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
MichaelBulla |
Posted: Fri Oct 06, 2006 3:49 am Post subject: |
|
|
Apprentice
Joined: 27 Sep 2006 Posts: 31 Location: Hamburg/Germany
|
jefflowrey wrote: |
You should keep the configuration part separate from your actual business application. Put it in an installer, or simply provide one or more MQSC scripts that can be run against some queue manager. |
Yes, thats what I meant, I write an installer. I cant use scripts because there is much more I have to prepare: MQ and an MQe Bridge and theres a lot of stuff I have to do dynamically.
I look for something in MQs world, that looks from my business application's view like a normal queue, but this queue distributes all messages to some predefined other queues. Distribution lists seem to be such a thing, but in an example I found to send to a distribution list, it was handled in an other way then queues. My business application will use JMS, so can I use JMS to talk to those distribution lists? |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Oct 06, 2006 4:04 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
A distribution list is an application construct - it does not exist in the MQ infrastructure.
I don't believe that JMS supports the notion of distribution lists. I believe you will have to use an array of Queue Destinations, and do a .send() on each one.
If you really are using JMS exclusively, then maybe using Pub/Sub is what you want instead. But it's a lot more work to configure from scripts.
There's a large number of steps that has to happen from when you have just installed MQ to when you have a Pub/Sub environment up and running - and even more steps after that to build the JMS configurations you'll need. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
MichaelBulla |
Posted: Fri Oct 06, 2006 4:33 am Post subject: |
|
|
Apprentice
Joined: 27 Sep 2006 Posts: 31 Location: Hamburg/Germany
|
OK, thanks.
Thats not, what I wanted to hear, but at least I dont feel stupid anymore, cause it really seems to be a complicated task. |
|
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
|
|
|
|