Return-Path: Delivered-To: apmail-camel-dev-archive@www.apache.org Received: (qmail 64493 invoked from network); 17 May 2010 14:19:26 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 17 May 2010 14:19:26 -0000 Received: (qmail 57228 invoked by uid 500); 17 May 2010 14:19:26 -0000 Delivered-To: apmail-camel-dev-archive@camel.apache.org Received: (qmail 57060 invoked by uid 500); 17 May 2010 14:19:26 -0000 Mailing-List: contact dev-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list dev@camel.apache.org Received: (qmail 57044 invoked by uid 500); 17 May 2010 14:19:26 -0000 Delivered-To: apmail-activemq-camel-dev@activemq.apache.org Received: (qmail 57038 invoked by uid 99); 17 May 2010 14:19:26 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 17 May 2010 14:19:26 +0000 X-ASF-Spam-Status: No, hits=-1434.3 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 17 May 2010 14:19:25 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o4HEJ4d6010937 for ; Mon, 17 May 2010 14:19:05 GMT Message-ID: <6007573.611274105944383.JavaMail.jira@thor> Date: Mon, 17 May 2010 10:19:04 -0400 (EDT) From: "Sergio Bossa (JIRA)" To: camel-dev@activemq.apache.org Subject: [jira] Created: (CAMEL-2729) Enable transaction propagation for SEDA component MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: ae95407df07c98740808b2ef9da0087c Enable transaction propagation for SEDA component ------------------------------------------------- Key: CAMEL-2729 URL: https://issues.apache.org/activemq/browse/CAMEL-2729 Project: Apache Camel Issue Type: Improvement Affects Versions: 2.2.0 Reporter: Sergio Bossa Attachments: seda-camel.zip I was recently working on a pure SEDA prototype based on Camel and ActiveMQ, and the biggest problem I had was the lack of transaction propagation among stages/threads, due to the Spring transaction-per-thread model which Camel relies on. Hence, it is currently impossible to commit/rollback transactions from a different stage than the one that initiated it. So, I developed a patch to org.apache.camel.component.jms.JmsConfiguration class in order to use a custom org.springframework.jms.listener.AbstractMessageListenerContainer which enables external transaction management. Then, I developed a Camel bean component to bind and propagate transactional resources among threads, and manually commit/rollback transactions. I'm attaching a sample project containing and showcasing all this stuff: it reads from an ActiveMQ queue, does dummy processing, and puts on another queue. In order to run: $> mvn test In order to run with an injected fault and do rollback: $> mvn test -Pfault-test WARN: requires a local ActiveMQ broker at tcp://localhost:61616 I'd like to gain some feedback and eventually talk about including such a features into Camel code base, which would require to: 1) Patch JmsConfiguration in order to allow injection of external AbstractMessageListenerContainer implementations. 2) Patch JmsConfiguration in order to avoid forcing to set the TransactionManager. 3) Somewhat enrich the Seda component to natively support transaction propagation. Feel free to ask any question, and thanks for listening! -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.