Author |
Message
|
Monk |
Posted: Wed Apr 01, 2009 12:22 am Post subject: MQ Pub/Sub not working with message exits enabled |
|
|
 Master
Joined: 21 Apr 2007 Posts: 282
|
Hi All,
This is a question related to MQ v7 pub/sub
I m running MQ v7.0.0.1 on aix 5.3
I m experimenting with pub/sub feature
My scenario is that one queue manager(QM1) is a publisher and i have another QM2 , which is a subsciber.
I want to connect them in such a way as to do pub/sub with 2 QMs
i.e MQApp ->(pub) -> QM1 -> QM2 <- (sub) MQApp.
but for this i need to connect QM1 and QM2 using standard distributed queuing techniques which is fine.the pub sub works in this fashion
But when i enable a simple message exit on my channels b/n QM1 and QM2 , the pub/sub fails.
the message exit simply logs the message to a file and a copy to a queue.it does not modify the message or MQMD in anyway.
Can someone tell me if i doing something wrong?
Thanks. _________________ Thimk |
|
Back to top |
|
 |
Vitor |
Posted: Wed Apr 01, 2009 1:35 am Post subject: Re: MQ Pub/Sub not working with message exits enabled |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Monk wrote: |
But when i enable a simple message exit on my channels b/n QM1 and QM2 , the pub/sub fails.
|
Fails how? Error code? Error message? Machine explodes? Swarm of locusts outside? Martian war machine asking for the address of a local chemist that sells flu remedies?
More information in, more assistance out. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
Monk |
Posted: Wed Apr 01, 2009 1:49 am Post subject: |
|
|
 Master
Joined: 21 Apr 2007 Posts: 282
|
Poobah,
When i say pub/sub fails , i mean the MQApps are not able to communicate using pub/sub , that means the publishing applications work fine , they can publish successfully, But the subscribing applicaitons fails , they do not get the messages from the topics.
But if i remove the message exits on the channels , I am able to get the messages from topics.
Let me know if more info is required to solve this mystery...
 _________________ Thimk |
|
Back to top |
|
 |
WMBDEV1 |
Posted: Wed Apr 01, 2009 2:03 am Post subject: Re: MQ Pub/Sub not working with message exits enabled |
|
|
Sentinel
Joined: 05 Mar 2009 Posts: 888 Location: UK
|
Vitor wrote: |
Martian war machine asking for the address of a local chemist that sells flu remedies? |
This happened to me once when I tried to write a channel exit. I've learned to keep well away since  |
|
Back to top |
|
 |
Vitor |
Posted: Wed Apr 01, 2009 2:20 am Post subject: Re: MQ Pub/Sub not working with message exits enabled |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
WMBDEV1 wrote: |
Vitor wrote: |
Martian war machine asking for the address of a local chemist that sells flu remedies? |
This happened to me once when I tried to write a channel exit. I've learned to keep well away since  |
One of the many reasons to avoid exits....  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
Vitor |
Posted: Wed Apr 01, 2009 2:23 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Monk wrote: |
But the subscribing applicaitons fails , they do not get the messages from the topics. |
Now we're getting to it. Does the subscribing application fail with a given reason code (even if the code is a "harmless" 2033 because it thinks there's no subscription when there clearly should be), a particular error message or what?
Or is it just shot by the Martian war machine as it makes for the chemist? _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
Monk |
Posted: Wed Apr 01, 2009 2:45 am Post subject: |
|
|
 Master
Joined: 21 Apr 2007 Posts: 282
|
yes poobah,
Im getting a MQRC_NO_MORE_MESSAGES i have set a timeout of 30 secs
but i dont think pub/sub could be doing heavy processing . to be sure i even set unlimited timeout...and just waited and waited... but nothing...
and another thing poobah,
what is the joke with
Quote: |
Martian war machine asking for the address of a local chemist that sells flu remedies? |
I m not familiar with this one..
 _________________ Thimk |
|
Back to top |
|
 |
WMBDEV1 |
Posted: Wed Apr 01, 2009 2:49 am Post subject: |
|
|
Sentinel
Joined: 05 Mar 2009 Posts: 888 Location: UK
|
Monk wrote: |
what is the joke with
Quote: |
Martian war machine asking for the address of a local chemist that sells flu remedies? |
I m not familiar with this one..
 |
If I told you, it would ruin the ending to the film, the war of the worlds  |
|
Back to top |
|
 |
Monk |
Posted: Wed Apr 01, 2009 3:02 am Post subject: |
|
|
 Master
Joined: 21 Apr 2007 Posts: 282
|
Quote: |
If I told you, it would ruin the ending to the film, the war of the worlds |
But we not watching the film rite now... , so its ok to ruin the ending.. _________________ Thimk |
|
Back to top |
|
 |
WMBDEV1 |
Posted: Wed Apr 01, 2009 3:08 am Post subject: |
|
|
Sentinel
Joined: 05 Mar 2009 Posts: 888 Location: UK
|
Then be patient, all will become clear in about 90 minutes.  |
|
Back to top |
|
 |
Monk |
Posted: Wed Apr 01, 2009 3:15 am Post subject: |
|
|
 Master
Joined: 21 Apr 2007 Posts: 282
|
Ok. I will just wait for you to finish with the film...  _________________ Thimk |
|
Back to top |
|
 |
Vitor |
Posted: Wed Apr 01, 2009 3:30 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Monk wrote: |
Im getting a MQRC_NO_MORE_MESSAGES i have set a timeout of 30 secs
but i dont think pub/sub could be doing heavy processing . to be sure i even set unlimited timeout...and just waited and waited... but nothing... |
So without channel exits the messages arrive, but with the exits they don't? I suspect a trace of your exit code will be illuminating.
Aside from the risk of Martian war machines, it does sound like your exit is not doing anything I'd approve of. A quick search of this forum will reveal my views on a) the need for the auditing of messages and b) the validity of using an exit (a dangerous bit of code at the best of times) to do it.
Especially in a pub/sub model, where it's very easy to obtain extra copies of a given message without an exit.
Monk wrote: |
what is the joke with
Quote: |
Martian war machine asking for the address of a local chemist that sells flu remedies? |
I m not familiar with this one..
 |
Too much coffee my end I suspect. A lot of people doing strange, stupid and impossible things. I have an urge to throw them all down a deep, dark Wells..... _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
Monk |
Posted: Wed Apr 01, 2009 9:37 pm Post subject: |
|
|
 Master
Joined: 21 Apr 2007 Posts: 282
|
Poobah,
I even tried setting up a dummy message exit in my pub/sub topology..
and i still getting the same result...
this could mean that
1. there is a bug in the pub/sub engine.
2. we are not configuring message exits properly in a pub/sub topology.
What do you think? _________________ Thimk |
|
Back to top |
|
 |
vol |
Posted: Wed Apr 01, 2009 9:50 pm Post subject: |
|
|
Acolyte
Joined: 01 Feb 2009 Posts: 69
|
Clearly this is nothing to do with pubsub, since by the time the msg exit is called the pubsub engine in the qmgr has long since put the msg to the subscriber queue.
Easily the most likely cause is that the msg exit is wrongly configured such that the channel to the qmgr which is the destination for the subscription fails to start. If this is the case, the qmgr error logs will show it. Look in /var/mqm/qmgrs/QMGRNAME/errors/AMQERR*LOG for any such entries. You could also check the xmitq to the remote qmgr to see whether the msgs are stranded there because the channel did not start. |
|
Back to top |
|
 |
Monk |
Posted: Wed Apr 01, 2009 10:05 pm Post subject: |
|
|
 Master
Joined: 21 Apr 2007 Posts: 282
|
Vol,
Quote: |
Clearly this is nothing to do with pubsub, since by the time the msg exit is called the pubsub engine in the qmgr has long since put the msg to the subscriber queue. |
We dont know where the message are going at the subscriber side.We looked everywhere, the DLQs , xmitqs..and dynamic queues..
Quote: |
Easily the most likely cause is that the msg exit is wrongly configured such that the channel to the qmgr which is the destination for the subscription fails to start. If this is the case, the qmgr error logs will show it. Look in /var/mqm/qmgrs/QMGRNAME/errors/AMQERR*LOG for any such entries. You could also check the xmitq to the remote qmgr to see whether the msgs are stranded there because the channel did not start. |
I dont think message exits could be configured wrongly , coz thy work fine when i dont use pub/sub
and no errors show up in the error logs..and the channels also dont go down.
Its getting harder to pin point the error in the pub/sub with message exits enabled.. _________________ Thimk |
|
Back to top |
|
 |
|