Return-Path: Delivered-To: apmail-activemq-users-archive@www.apache.org Received: (qmail 81730 invoked from network); 15 Sep 2009 03:15:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 15 Sep 2009 03:15:37 -0000 Received: (qmail 72825 invoked by uid 500); 15 Sep 2009 03:15:37 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 72730 invoked by uid 500); 15 Sep 2009 03:15:37 -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 72720 invoked by uid 99); 15 Sep 2009 03:15:36 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Sep 2009 03:15:36 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of bruce.snyder@gmail.com designates 209.85.220.220 as permitted sender) Received: from [209.85.220.220] (HELO mail-fx0-f220.google.com) (209.85.220.220) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Sep 2009 03:15:25 +0000 Received: by fxm20 with SMTP id 20so2615697fxm.38 for ; Mon, 14 Sep 2009 20:15:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=SaitvAMztCozL6MiTHoXfkTO79F6lXStcvcpLCa6xdQ=; b=pqNJzMjJu5pI0aBgJMZxB0r4EvKIZS/oF2ryikJ4Qh6bd8yXz2xMDPm86jBBQj8hIY nLutP37/htCAIf6yAvX1V4s8eHEq84OrQunMWg+U+R6GpQQ6+HpgvnR8ek0Ued6AX8KA kl7OAXsh4rd9CTqcXnTxDt2PLA8wcEeIRn5d0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=glpc/od14J9v8MsbF8SLrr+G6/PxzWBwCTryBnHSvDDblFf1IhZdgSjFvNRMOKK47Z e8cjt0vtBj2k1lcp/T0VDsuvZBP32qCay7MTfMHFmMsEyP57B8h5/L5f9cqnKCFS38bU 67bNW+i7PAG7afJQZ3lVk8PL5vt7gziBI6yC8= MIME-Version: 1.0 Received: by 10.223.2.75 with SMTP id 11mr2452732fai.54.1252984504875; Mon, 14 Sep 2009 20:15:04 -0700 (PDT) In-Reply-To: <25440673.post@talk.nabble.com> References: <25440673.post@talk.nabble.com> Date: Mon, 14 Sep 2009 21:15:04 -0600 Message-ID: <7b3355cb0909142015g56802671q429a0e98bbf2562@mail.gmail.com> Subject: Re: Duplicate Messages on Listener Restart From: Bruce Snyder To: users@activemq.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org On Mon, Sep 14, 2009 at 12:25 PM, dbczak wrote: > > Hi, > > I have a message client that produces a message and sends to multiple > listeners by using the URL: > fanout:(static:(tcp://host1:61616,tcp://host2:61616,tcp://host3:61616 > ...))?fanOutQueues=3Dtrue&minAckCount=3D1 > > I'm getting duplicate messages whenever any of the listener is shut down = and > restarted but the sender is not. =A0For example: > > I start 2 listeners. > I run the sender which sends one message - both listeners receive and > acknowledge. > I shut down one of the listeners. > The sender then sends another message which only reaches one of the > listeners. > I bring the listener that is down back up. =A0- At this point, this liste= ner > receives both the first message that it already processed and the new > message it missed. =A0It should only receive the one it missed, but I can= 't > stop the other one from coming in too. > > The code for both the listener (TIPServer.java) and sender (TIPClient.jav= a) > are attached. > > http://www.nabble.com/file/p25440673/TIPServer.java TIPServer.java > > http://www.nabble.com/file/p25440673/TIPClient.java TIPClient.java What behavior are you expecting by using the fanout transport and the fanOutQueues=3Dtrue transport option? Please make sure to read everything on the following page regarding the fanout transport: http://activemq.apache.org/fanout-transport-reference.html Bruce --=20 perl -e 'print unpack("u30","D0G)U8V4\@4VYY9&5R\"F)R=3D6-E+G-N>61E