|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Reason code handling |
« View previous topic :: View next topic » |
Author |
Message
|
drzhiwang |
Posted: Wed Feb 18, 2004 12:39 pm Post subject: Reason code handling |
|
|
Newbie
Joined: 18 Feb 2004 Posts: 1
|
There are hundreds of reason codes.
What is the best practice for handling Websphere MQ reason codes?
For example, reason code 2003 may happen for long running transactions, which fill up log spaces. When such exception occurs, we just roll back the transaction. Since some reason codes are fatal and some are not, it is hard or impossible to check all of them. What is the best way to deal with them.
Thanks. |
|
Back to top |
|
 |
kman |
Posted: Mon Mar 08, 2004 12:12 am Post subject: |
|
|
Partisan
Joined: 21 Jan 2003 Posts: 309 Location: Kuala Lumpur, Malaysia
|
I might think not doing the erroneous code could help alleviate the problem.
The reason codes are there to tell you what is the problem you are getting, and the manuals are there to help get around it.
You have to deal with the reason codes as you get it. I might add that even if you are a seasoned mq programmer, you could still get reason codes unexpectedly.
Someone says. 'It depends' |
|
Back to top |
|
 |
bduncan |
Posted: Mon Mar 08, 2004 1:39 pm Post subject: |
|
|
Padawan
Joined: 11 Apr 2001 Posts: 1554 Location: Silicon Valley
|
It is up to you to determine what to do when you get a particular return code, because it depends on your specific architecture/business needs etc...
A good example is 2033. This is returned when you issue an MQGET with some wait time, and it expires without any message being retrieved. The fact that no message was found may be significant to your application, in which case you'll do some processing. For instance, in a real-time system, perhaps I send a message and my code will only wait 5 seconds for an answer. If the answer doesn't come in 5 seconds, I don't continue to wait. I do something else, because this is a real-time system.
On the other hand, if I'm simply polling a queue, then I don't care if I get a 2033, I just try again. _________________ 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
|
|
|
|