Author |
Message
|
stallin |
Posted: Thu Jan 10, 2013 1:15 am Post subject: MQ Triggering Query |
|
|
Novice
Joined: 11 Jan 2009 Posts: 21
|
Hi,
For every message (M) coming to our queues, We want to take a copy of the message (M-copy) and the MQMD message id of M, source queue name for tracking. We want to do this before the message gets into the application flows and preferably at MQ level.
Publish/Subscribe - making queue alias to a topic etc. does not suite us as though we will get the copy of the message we would not be able to get the other information.
Another option we thought is to put a trigger program to do this on every message arrival.
My question is will a trigger program be able to act on (copy) the message which arrives, while a application is listening to it? Will the message wait till the trigger gets completed or it does not?
Is there any other option?
Thanks,
SV |
|
Back to top |
|
 |
zpat |
Posted: Thu Jan 10, 2013 1:20 am Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
Triggering doesn't hold the message.
In fact if the triggered queue is already open for input the trigger won't even fire (this is triggering 101 !).
Do you have WMB available? Otherwise just code your own message duplicator and send the message from one input queue to two output queues.
The only way you can do what you want without impacting the topology would be to use a message exit (maybe the API crossing exit). |
|
Back to top |
|
 |
stallin |
Posted: Thu Jan 10, 2013 1:32 am Post subject: |
|
|
Novice
Joined: 11 Jan 2009 Posts: 21
|
Thank you. We do have WMB and was considering doing there as last option. Since there are several existing flows receiving messages from client applications, we have to embed this dupilcation logic everywhere or deploy this duplicator with all the i/p queues and divert it to the existing flows with different queue names (latter is maintenance nightmare). |
|
Back to top |
|
 |
fatherjack |
Posted: Thu Jan 10, 2013 1:39 am Post subject: |
|
|
 Knight
Joined: 14 Apr 2010 Posts: 522 Location: Craggy Island
|
Aren't there 3rd party tools for doing this sort of thing? _________________ Never let the facts get in the way of a good theory. |
|
Back to top |
|
 |
zpat |
Posted: Thu Jan 10, 2013 2:30 am Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
There is a commercial product that uses the API crossing exit.
There also used to be a free program that did this using the API exit (mirrorq). I still have the source for this but it's fairly old code (from IBM 2004).
Either way, this is a low level (i.e. deep) change to MQ that should not be undertaken lightly.
You might be able to use alias queues to reduce the hassle of changing some of the queue references. |
|
Back to top |
|
 |
mqjeff |
Posted: Thu Jan 10, 2013 3:11 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
there's really no such thing as a source queue. |
|
Back to top |
|
 |
stallin |
Posted: Thu Jan 10, 2013 3:37 am Post subject: |
|
|
Novice
Joined: 11 Jan 2009 Posts: 21
|
Thanks zpat, I will explore.
Quote: |
there's really no such thing as a source queue |
I used the Message Broker MQMD.SourceQueue terminology to mean the queue name where the message came to, it will be required if the message needs to be reprocessed. |
|
Back to top |
|
 |
elkinsc |
Posted: Mon Jan 14, 2013 9:05 am Post subject: API Crossing exit |
|
|
 Centurion
Joined: 29 Dec 2004 Posts: 138 Location: Indy
|
Please note that on z/OS an API crossing exit is is only available under CICS. |
|
Back to top |
|
 |
RogerLacroix |
Posted: Mon Jan 14, 2013 5:26 pm Post subject: |
|
|
 Jedi Knight
Joined: 15 May 2001 Posts: 3264 Location: London, ON Canada
|
|
Back to top |
|
 |
|