[ https://issues.apache.org/activemq/browse/SM-1120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_40530 ]
Martin Landua commented on SM-1120: ----------------------------------- Sorry, forgot to attach the patch. Index: C:/jboss/servicemix-SNAPSHOT/common/servicemix-common/src/main/java/org/apache/servicemix/common/BaseLifeCycle.java =================================================================== --- C:/jboss/servicemix-SNAPSHOT/common/servicemix-common/src/main/java/org/apache/servicemix/common/BaseLifeCycle.java (revision 590120) +++ C:/jboss/servicemix-SNAPSHOT/common/servicemix-common/src/main/java/org/apache/servicemix/common/BaseLifeCycle.java (working copy) @@ -44,7 +44,8 @@ public void onMessageExchange(MessageExchange exchange) { try { processExchange(exchange); - } catch (Exception e) { + } catch (Throwable t) { + Exception e = new Exception(t); logger.error("Error processing exchange " + exchange, e); try { // If we are transacted and this is a runtime exception > Throwable is not cought in BaseLifeCycle which can result in open transactions > ------------------------------------------------------------------------------ > > Key: SM-1120 > URL: https://issues.apache.org/activemq/browse/SM-1120 > Project: ServiceMix > Issue Type: Bug > Components: servicemix-common > Affects Versions: 3.1 > Environment: Everywhere > Reporter: Martin Landua > > The onMessageExchange method in BaseLifeCycle only catches Exceptions. If a > Throwable is thrown during processing of the Message Exchange, the > transaction will not be rolled back. > As a result, the transaction keeps associated with the thread, which is > returned to the thread pool. Whenever this thread is being reused, it may > lead to "Already associated to a transaction" exception in any further > message processing (which is not related to the actual problem in any way). > Best regards > Martin Landua -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.