|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
mq -java problem |
« View previous topic :: View next topic » |
Author |
Message
|
rita |
Posted: Fri Jan 11, 2002 11:04 am Post subject: |
|
|
Novice
Joined: 31 Dec 2001 Posts: 17
|
hi
i am having this skanky prob with mq base java....
i wrote 2 simple programs one for put and one get.
first i used PUT program to put 100 messages.
next i used the PUT and GET programs in conjunction.
now first the queueDepth increases to 200 and GET takes out all the messages....
but it is taking out only 100 messages and gives error 2033 which is - An MQGET call was issued, but there is no message on the queue satisfying the selection criteria specified in MQMD.... huh
i dont think any wait time has to be specified ...
how would i solve this ???
thanks in advance
rita |
|
Back to top |
|
 |
PeterPotkay |
Posted: Fri Jan 11, 2002 12:16 pm Post subject: |
|
|
 Poobah
Joined: 15 May 2001 Posts: 7722
|
Here's a guess. Your first 100 messages are expired. Expired message still show up in queue depth. The way to prove this is after u get the 2033 after u got the 100 messages, is your queue depth now zero? (the get of the 2nd 100 messages will cause the 1st 100 to be wiped clean from the queue and the queue depth. remember an expired message is simply a message that is ineligible to be gotten; it is still on the queue till MQ removes it)
_________________ Peter Potkay
Keep Calm and MQ On |
|
Back to top |
|
 |
bduncan |
Posted: Fri Jan 11, 2002 1:25 pm Post subject: |
|
|
Padawan
Joined: 11 Apr 2001 Posts: 1554 Location: Silicon Valley
|
I agree with Peter. You also mentioned:
"i dont think any wait time has to be specified"
If you are running the GET and PUT programs in a decoupled fashion, yes, but if you are running them simulaneously, you can run into the situation where the messages from the PUT program aren't being delivered as quickly as the GET program is consuming them (in fact this is usually the case, esp. if you are going over a network) then the GET program will issue an MQGET, see there are no queued messages, and immediately return a 2033. In the subsequent moments, a message may in fact arrive, but the GET program has already ended. For this reason, it is recommended to put a WAIT time in the GET program so that when it sees there are no messages on the queue it will stick around for some time before throwing the 2033.
_________________ Brandon Duncan
IBM Certified MQSeries Specialist
MQSeries.net forum moderator |
|
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
|
|
|
|