Return-Path: X-Original-To: apmail-activemq-dev-archive@www.apache.org Delivered-To: apmail-activemq-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EF44EFF63 for ; Wed, 3 Apr 2013 22:45:15 +0000 (UTC) Received: (qmail 53332 invoked by uid 500); 3 Apr 2013 22:45:15 -0000 Delivered-To: apmail-activemq-dev-archive@activemq.apache.org Received: (qmail 53244 invoked by uid 500); 3 Apr 2013 22:45:15 -0000 Mailing-List: contact dev-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list dev@activemq.apache.org Received: (qmail 53235 invoked by uid 99); 3 Apr 2013 22:45:15 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 03 Apr 2013 22:45:15 +0000 Date: Wed, 3 Apr 2013 22:45:15 +0000 (UTC) From: "Timothy Bish (JIRA)" To: dev@activemq.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (AMQCPP-367) failover: receiving duplicate messages after a broker restart MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/AMQCPP-367?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Timothy Bish updated AMQCPP-367: -------------------------------- Fix Version/s: (was: 3.6.1) 3.7.0 > failover: receiving duplicate messages after a broker restart > ------------------------------------------------------------- > > Key: AMQCPP-367 > URL: https://issues.apache.org/jira/browse/AMQCPP-367 > Project: ActiveMQ C++ Client > Issue Type: New Feature > Components: CMS Impl > Affects Versions: 3.4.0 > Environment: GNU/Linux > Reporter: Chris Hoffmann > Assignee: Timothy Bish > Fix For: 3.7.0 > > > When testing AMQCPP-364/AMQCPP-363, we noticed that on broker shutdown, a listener receives a message twice through onMessage callbacks. > Testcase for a 5.3 broker > 1) In the onMessage before acknowledging the message, shutdown the broker. > 2) Then acknowledge the message while broker is still off. > 3) Bring the broker back up and you see the message delivered again to the onMessage () callback. > With a 5.5 broker, the problem also happens when ack'ing the message when the broker is back alive. When ack'ing the firs message, you see an error messag in the broker log: > WARN | Ignoring ack received before dispatch; result of failover with an outstanding ack. Acked messages will be replayed if present on this broker. > Ignored ack: MessageAck {commandId = 22, responseRequired = false, ackType = 2, consumerId = ID:HOSTNAME-44923-1303316424844-0:0:0:0, > firstMessageId = ID:HOSTNAME-58084-1303317597544-0:0:0:0:0, > lastMessageId = ID:HOSTNAME-58084-1303317597544-0:0:0:0:0, > destination = queue://TESTQUEUE, transactionId = null, messageCount = 1, poisonCause = null} > A java test program (e.g. the ones in the activeMQ examples directory) work fine: no message duplicates there. When the message gets redelivered to a different client, the second ack'ing results in an exception raised to the java client. > Kind regards, > Chris -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira