Return-Path: X-Original-To: apmail-activemq-users-archive@www.apache.org Delivered-To: apmail-activemq-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 84328F5BD for ; Mon, 15 Apr 2013 14:44:31 +0000 (UTC) Received: (qmail 1912 invoked by uid 500); 15 Apr 2013 14:44:31 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 1876 invoked by uid 500); 15 Apr 2013 14:44:30 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 1868 invoked by uid 99); 15 Apr 2013 14:44:30 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Apr 2013 14:44:30 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of suonayi2006@163.com designates 220.181.13.144 as permitted sender) Received: from [220.181.13.144] (HELO m13-144.163.com) (220.181.13.144) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Apr 2013 14:44:24 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=Received:Date:From:To:Subject:In-Reply-To: References:Content-Type:MIME-Version:Message-ID; bh=MDgWy+PH0X0E A08KS8IPZJmE62vmKyvMEDE+MiUTrJ8=; b=QAGuidziEr4/37MFH55XIvadvxbY 9eO/Y0AYqkho8U6a3mDhqHcrKFneEZr/qtwuci2P/FU4Y1+hgaA+8iWxs1exz3lc N24vBfBMR8pgWt+PTVtdsAAfiOkVTHgXqLrK4D9QtLCdVcpuVukzYVWmFOsLkWTt rpRnLJJkXfRQeVo= Received: from suonayi2006$163.com ( [114.249.246.127] ) by ajax-webmail-wmsvr144 (Coremail) ; Mon, 15 Apr 2013 22:43:57 +0800 (CST) X-Originating-IP: [114.249.246.127] Date: Mon, 15 Apr 2013 22:43:57 +0800 (CST) From: SuoNayi To: users@activemq.apache.org Subject: Re:XA transaction not working on Broker redelivery. X-Priority: 3 X-Mailer: Coremail Webmail Server Version SP_ntes V3.5 build 20130201(21528.5249.5248) Copyright (c) 2002-2013 www.mailtech.cn 163com In-Reply-To: <9829_1366035080_516C0A88_9829_3577_1_3B1570378207D64B9E263522B47BE1EEB613137F94@PUEXCB2C.nanterre.francetelecom.fr> References: <9829_1366035080_516C0A88_9829_3577_1_3B1570378207D64B9E263522B47BE1EEB613137F94@PUEXCB2C.nanterre.francetelecom.fr> X-CM-CTRLDATA: ReLaimZvb3Rlcl9odG09NDk5NTo4MQ== Content-Type: multipart/alternative; boundary="----=_Part_329319_1025592986.1366037037811" MIME-Version: 1.0 Message-ID: <74f05ca2.15aeb.13e0e2702f4.Coremail.suonayi2006@163.com> X-CM-TRANSID: kMGowEAZUUQuEmxR6CkgAA--.811W X-CM-SenderInfo: xvxr0td1lsiiqw6rljoofrz/1tbiTBAAGlEADguM5gABs5 X-Coremail-Antispam: 1U5529EdanIXcx71UUUUU7vcSsGvfC2KfnxnUU== X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_329319_1025592986.1366037037811 Content-Type: text/plain; charset=GBK Content-Transfer-Encoding: 7bit Broker redelivery function uses scheduler to redeliver messages. B/w scheduled messages are out of any transactions so you will see the repsonse messages even if rollback is performed. At 2013-04-15 22:11:09,guillaume.surrel@orange.com wrote: >Hello, > >I'm having some troubles using redelivery plugin and XA transactions. I'm using a spring listener-container and JtaTransactionManager in an application server. I'm using ActiveMQ 5.8.0. > >When the listener receives the message, we write it into a database and send a response message during the transaction. In order to test the rollback of the transaction, we throw an exception before the end of transaction. > >When using client redelivery (jms.redeliveryPolicy.maximumRedeliveries=3), everything works as expected: the response message is not sent and the message is not persisted. > >But when using broker redelivery plugin, the behavior is different. After the redelivery delay, the message is sent again but the XA is not working anymore on the messaging side: the response message is sent anyway. So after sending 1 message, I end up with 1 message in my dead letter queue (expected), an empty database (expected), and various duplicate message responses (should be 0). > >This is my configuration of the redelivery plugin : > > > > > > > > > > > > >Has anyone experienced similar problems ? Am I missing something about broker redelivery ? > >Thank you, >Guillaume > >_________________________________________________________________________________________________________________________ > >Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc >pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler >a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration, >France Telecom - Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci. > >This message and its attachments may contain confidential or privileged information that may be protected by law; >they should not be distributed, used or copied without authorisation. >If you have received this email in error, please notify the sender and delete this message and its attachments. >As emails may be altered, France Telecom - Orange is not liable for messages that have been modified, changed or falsified. >Thank you. > ------=_Part_329319_1025592986.1366037037811--