activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dnn <Daniel.Nawro...@ngc.com>
Subject Suspended Transaction not making it to a DLQ?
Date Mon, 19 Apr 2010 17:37:58 GMT

I am currently working on the error handling for my application.  I have set
up a DLQ so that when my app throws an exception, the XA transaction will
rollback everything and let ActiveMQ redeliver the message to try again. 
After 6 failures, ActiveMQ will move the message to a DLQ.  I have noticed
that it works as expected when all the work is done inside a single XA
transaction.  However, if I start & commit a new XA transaction (method
annotated with the Spring TRANSACTION_REQUIRES_NEW), then throw the
exception, the message is rolled back successfully, but never gets moved to
the DLQ and ends up in an infinite loop!

I am using ActiveMQ 5.3.1, Camel 2.2.0, Spring 2.5.6, and Bitronix 1.3.3. 
My Camel route is roughly:

<from uri="jms:queue:start1"/>
<transacted/>
<to uri="aProcessorAnnotatedWIth_TRANSACTION_REQUIRES_NEW"/>
<to uri="aProcessorThatThrowsAnException"/>
<to uri="jms:queue:end1"/>

With the "aProcessorAnnotatedWIth_TRANSACTION_REQUIRES_NEW" processor, the
message never hits the DLQ and my app spins indefinitely.  If I comment it
out, the message makes it to the DLQ as expected.

Has anyone ever seen an error like this?

Thanks,
Dan Nawrocki

-- 
View this message in context: http://old.nabble.com/Suspended-Transaction-not-making-it-to-a-DLQ--tp28287721p28287721.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message