Author |
Message
|
j1 |
Posted: Sun Aug 23, 2009 3:02 pm Post subject: Reading Messages off a Remote Queue? |
|
|
 Centurion
Joined: 23 Jun 2003 Posts: 139
|
Hi,
Please excuse if this is a dumb MQ 101 question, but I am seemingly in a predicament.
I am setting up a message feed wherein the messages will be coming in and be physically resident on an MQ server A and I need to read them off that queue by connecting to MQ server B. I am thinking of using Remote Queue Definitions but it is seemingly meant for put's rather than get's (given the sdr--> receiver chl defintion for the xmitq). I dont htink clustering also allows 'getting' from a clustered queue. Wondering what would be the way out of this.
Appreciate any help.
Thx |
|
Back to top |
|
 |
gbaddeley |
Posted: Sun Aug 23, 2009 3:36 pm Post subject: |
|
|
 Jedi Knight
Joined: 25 Mar 2003 Posts: 2538 Location: Melbourne, Australia
|
You are correct, it is only possible to GET messages that are queued on the Queue Manager that you are connected to.
If they are on a remote Queue Manager (eg. on another system) you can use MQ Client to connect. Whether that is a good decision in terms of your design is another matter...
You could also change your design so that the messages are routed to your local Queue Manager. _________________ Glenn |
|
Back to top |
|
 |
Vitor |
Posted: Sun Aug 23, 2009 3:41 pm Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
gbaddeley wrote: |
You are correct, it is only possible to GET messages that are queued on the Queue Manager that you are connected to. |
I'll also confirm that you're right, you can't "get" from a clustered queue that's not hosted by the queue manager you're connected to, for the reason so eloquently given above. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
j1 |
Posted: Sun Aug 23, 2009 4:43 pm Post subject: |
|
|
 Centurion
Joined: 23 Jun 2003 Posts: 139
|
the problem is that we are trying to have the messages stay resident on Qmanager B and at the same time read them off of Qmanager A, since the task that reads the messages is resident on qmgr A and connects to it. |
|
Back to top |
|
 |
Vitor |
Posted: Sun Aug 23, 2009 5:17 pm Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
j1 wrote: |
the problem is that we are trying to have the messages stay resident on Qmanager B and at the same time read them off of Qmanager A, since the task that reads the messages is resident on qmgr A and connects to it. |
The solution is to accept that WMQ is an assured delivery system and you don't need to keep the messages on queue manager B if they're successfully sent to queue manager A.
Or use pub/sub and send a message to both. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mqjeff |
Posted: Sun Aug 23, 2009 6:28 pm Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
j1 wrote: |
the problem is that we are trying to have the messages stay resident on Qmanager B and at the same time read them off of Qmanager A, since the task that reads the messages is resident on qmgr A and connects to it. |
I respectfully disagree.
The problem is that your business analysts have confused a technical requirement for a business requirement. Or your technical analysts have confused a technical requirement for a business requrirement.
Go back to the business requirement. If it says "log" or "audit" or "resend", then write pertinent information into a database. If it says "guarantee delivery", then lie back and trust MQ. |
|
Back to top |
|
 |
raj429 |
Posted: Mon Aug 24, 2009 1:33 am Post subject: |
|
|
Acolyte
Joined: 04 Jul 2009 Posts: 53
|
hi guys,
What about server-requester configuration for this..
QMA is having the messages and configure a server channel on this.
QMB has to pull the messages, so configure a requester channel on this queue manager.
trigger the requester channel whenever application sitting on QMB is requesting.
(this part is tricky if am not wrong).
requeter initiates the server and server channel will send the message to QMB and from there you can pick up the messages.
I have doubt about this kind of setup as i never done this before..but thought of it. I will test on my part |
|
Back to top |
|
 |
Mr Butcher |
Posted: Mon Aug 24, 2009 5:19 am Post subject: |
|
|
 Padawan
Joined: 23 May 2005 Posts: 1716
|
this will work only if the messages reside in the XMITQ on QMA that is used by the server channel.
if the messages sit in a local queue (usage normal) on QMA there is no way you "request" them from a QMB queuemanager.
if messages come in to QMA, and you need to process them on QMB, then define a channel from QMA to QMB. make the queue on QMA the messages are destigned to a remotequeue pointing to a local queue on QMB were you want the messages to be.
whatever you do with channels or queues or or, this all will not doublicate your messages so you have them in QMA and QMB (in case this is what you want), and there is no way to get them from a different queuemanager if they are in a local queue on QMA. _________________ Regards, Butcher |
|
Back to top |
|
 |
Ratan |
Posted: Wed Aug 26, 2009 1:23 am Post subject: |
|
|
 Grand Master
Joined: 18 Jul 2002 Posts: 1245
|
It is like saying you have a person in London and you want to pick him by you going to New York. Either you have to go to London or he has to come to New York.
Technically I dont see a reason why you are not sending the msgs from QM A to QM B. _________________ -Ratan |
|
Back to top |
|
 |
|