activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pmmerritt1 <pmmerr...@gmail.com>
Subject Exception following inner transaction fails to move message to DLQ
Date Tue, 20 Apr 2010 14:01:50 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? 
-- 
View this message in context: http://old.nabble.com/Exception-following-inner-transaction-fails-to-move-message-to-DLQ-tp28287861p28287861.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message