|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
QueueReceiver gives null but MQ get finds msg in WAS6/MQ5.3 |
« View previous topic :: View next topic » |
Author |
Message
|
rmpinchback |
Posted: Tue Aug 22, 2006 11:21 am Post subject: QueueReceiver gives null but MQ get finds msg in WAS6/MQ5.3 |
|
|
Newbie
Joined: 17 Aug 2006 Posts: 6
|
Ok, this one has me stumped.
I've got a simple situation where a remote app (not mine) can let me ping it; nice and convenient for development. It has two queues; one for requests and one for responses, both on the same QM. I'm trying to write an app on the other end to use only JMS for communicating with the remote app.
I can send messages to the remote app using either the MQ API or pure JMS, and I get responses back on the response queue as I would expect. Kind of.
I can pull the responses if I use the MQ API. If I try to use a JMS QueueReceiver.receive method, it doesn't see anything at all on the queue. I'm not even using a message selector; as far as the receiver is concerned, there is absolutely nothing on that queue. I can then tweak my code and seconds later pull the response that I know is on the queue. This is 100% consistent; MQ API pull works, QueueReceiver.receive gives a null message. No exceptions are thrown, no little warning messages anywhere I can see.
I get the JMS queues via JNDI. If I "toString" the response queue object, I can see it has the QM name as a part of its URL. When I send a message I set the JMSReplyTo to the response queue. The fact that I can pull the responses from the response queue via the MQ API proves that setting the reply-to is working. I'm literally using the same Java queue object for setting the reply-to that I use for polling via a QueueReceiver.
I have absolutely no idea what is going on. |
|
Back to top |
|
 |
rmpinchback |
Posted: Tue Aug 22, 2006 11:22 am Post subject: |
|
|
Newbie
Joined: 17 Aug 2006 Posts: 6
|
"MQ API pull works" should be "MQ API get works" |
|
Back to top |
|
 |
jefflowrey |
Posted: Tue Aug 22, 2006 11:25 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You have to issue the start method on the Queue Receiver. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
rmpinchback |
Posted: Tue Aug 22, 2006 11:31 am Post subject: |
|
|
Newbie
Joined: 17 Aug 2006 Posts: 6
|
Ok, feeling really stupid right about now....
Thanks, that was it. |
|
Back to top |
|
 |
rmpinchback |
Posted: Tue Aug 22, 2006 12:07 pm Post subject: |
|
|
Newbie
Joined: 17 Aug 2006 Posts: 6
|
(and for anybody else who runs into this problem in the future and hits this thread, the start method referred to is the one on the connection) |
|
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
|
|
|
|