Author |
Message
|
smartz |
Posted: Thu Apr 17, 2008 2:08 am Post subject: Inspect message backed out by BOQNAME/BOTHRESH |
|
|
Newbie
Joined: 18 Feb 2008 Posts: 9
|
Hi, I have the following configuration:
- local queue inQ1
- local queue inQ2
- local queue errQ
inQ1 and inQ2 are set with BOQNAME=errQ and BOTHRESH=X
Once a message fails on inQ1 or inQ2 X times it is backed out to errQ. This is working correctly.
The application is written using the JMS API.
Now the question:
while inspecting errQ with the JMS API, how can I determine which queue a message was backed out from?
Thanks in advance for any help |
|
Back to top |
|
 |
Vitor |
Posted: Thu Apr 17, 2008 2:20 am Post subject: Re: Inspect message backed out by BOQNAME/BOTHRESH |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
smartz wrote: |
while inspecting errQ with the JMS API, how can I determine which queue a message was backed out from?
|
By knowing which queue uses errQ as a backout queue?
AFAIK (and I'm by no means an experienced Java/JMS person) that information's not held anywhere on the message itself. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
smartz |
Posted: Thu Apr 17, 2008 2:25 am Post subject: |
|
|
Newbie
Joined: 18 Feb 2008 Posts: 9
|
Vitor, thanks for your reply.
The errQ is used as a backout by a number of queues - here simplified with inQ1 and inQ2. I would like to determine which one it came from to be able to repost the message to the correct queue - e.g. once the issue that caused it to fail has been resolved.
thanks again |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu Apr 17, 2008 3:01 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
There's nothing that will tell you which queue a message was backed out from.
This is why most people define more than one backout queue. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
Vitor |
Posted: Thu Apr 17, 2008 3:04 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
smartz wrote: |
I would like to determine which one it came from to be able to repost the message to the correct queue - e.g. once the issue that caused it to fail has been resolved.
|
I do understand your intent here, and do hope I'm wrong about the lack of original queue information. Like I said, not a strong Java person.
In my world, I've used separate queues and reposted from there. Architecturally, one backout queue or 20 is the same queue, handled in the same way - it stores the message, someone or something resolves the problem, the queue is reposted onto it's matching queue & everyone goes home. Simple.
The example that springs to mind is a dead application database, where a combination of Tivoli and a parameter driven script went through the process indicated above. But there was no Java involved there, so maybe there's a better way for you. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
fjb_saper |
Posted: Thu Apr 17, 2008 5:45 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
If you want to stay with one backout queue here is a "dirty way"
Do not define a backout queue on the queue, just the bo threshold.
Have a DLQ handler run on the DLQ. Have it move all the 2263 rc (or is it 2362? my memory is fading at the end of the day) to the backout queue with the header.
After the problem is fixed run a dlq handler on the backout queue and you can specify something like
Code: |
destq(my.original.queue) action(retry) |
Enjoy  _________________ MQ & Broker admin |
|
Back to top |
|
 |
smartz |
Posted: Fri Apr 18, 2008 1:24 am Post subject: |
|
|
Newbie
Joined: 18 Feb 2008 Posts: 9
|
fjb_saper wrote: |
If you want to stay with one backout queue here is a "dirty way"
Do not define a backout queue on the queue, just the bo threshold.
Have a DLQ handler run on the DLQ. Have it move all the 2263 rc (or is it 2362? my memory is fading at the end of the day) to the backout queue with the header.
After the problem is fixed run a dlq handler on the backout queue and you can specify something like
Code: |
destq(my.original.queue) action(retry) |
Enjoy  |
fjb_saper, thanks for the tip, I will most definitely give it a try! |
|
Back to top |
|
 |
|