Return-Path: Delivered-To: apmail-activemq-users-archive@www.apache.org Received: (qmail 97782 invoked from network); 23 Feb 2011 23:28:52 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 23 Feb 2011 23:28:52 -0000 Received: (qmail 68137 invoked by uid 500); 23 Feb 2011 23:28:52 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 67940 invoked by uid 500); 23 Feb 2011 23:28:51 -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 67932 invoked by uid 99); 23 Feb 2011 23:28:51 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 23 Feb 2011 23:28:51 +0000 X-ASF-Spam-Status: No, hits=2.0 required=5.0 tests=SPF_NEUTRAL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [216.139.236.26] (HELO sam.nabble.com) (216.139.236.26) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 23 Feb 2011 23:28:44 +0000 Received: from joe.nabble.com ([192.168.236.151]) by sam.nabble.com with esmtp (Exim 4.69) (envelope-from ) id 1PsO87-0003LQ-Ak for users@activemq.apache.org; Wed, 23 Feb 2011 15:28:23 -0800 Date: Wed, 23 Feb 2011 15:28:23 -0800 (PST) From: "tejalk@yahoo-inc.com" To: users@activemq.apache.org Message-ID: <1298503703307-3321887.post@n4.nabble.com> Subject: Getting duplicate messages with retroactive consumer MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Hi, We are evaluating ActiveMQ as a solution for our messaging broker. One of the requirements is to be able to replay messages received on a destination. When using retroactive consumer, I observed that the same set of messages get sent twice. Following is the scenario and steps followed: 1. Start a consumer C1 with a durable subscription sub1 on topic T1.(?consumer.retroactive=true when creating topic T1) 2. Bring the consumer C1 down 3. Send 5 messages between time t1-t2. 4. Again, send 10 messages between time t2-t3. 5. Now start another consumer C2 with durable subscription sub2 on topic T1 specifying the selector as "JMSTimestamp > t2 AND JMSTimestamp < t3" Consumer C2 gets the messages between t2-t3 twice. ie it gets 20 messages when it expects 10. This happens only for the "first" time when the consumer C2 is started. If the consumer C2 is brought down and started again, then it receives the expected 10 messages. We are using the following subscriptionRecoveryPolicy. Using activemq 5.3.2, jdk1.6 on Linux. Am I doing anything wrong or is this a bug? Thanks, Tejal -- View this message in context: http://activemq.2283324.n4.nabble.com/Getting-duplicate-messages-with-retroactive-consumer-tp3321887p3321887.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.