Return-Path: X-Original-To: apmail-activemq-commits-archive@www.apache.org Delivered-To: apmail-activemq-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 879D8D69C for ; Mon, 3 Dec 2012 18:19:10 +0000 (UTC) Received: (qmail 97851 invoked by uid 500); 3 Dec 2012 18:19:10 -0000 Delivered-To: apmail-activemq-commits-archive@activemq.apache.org Received: (qmail 97825 invoked by uid 500); 3 Dec 2012 18:19:10 -0000 Mailing-List: contact commits-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 commits@activemq.apache.org Received: (qmail 97818 invoked by uid 99); 3 Dec 2012 18:19:10 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 Dec 2012 18:19:10 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 Dec 2012 18:19:09 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 8095B2388AB9; Mon, 3 Dec 2012 18:18:49 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1416615 - /activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala Date: Mon, 03 Dec 2012 18:18:48 -0000 To: commits@activemq.apache.org From: chirino@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20121203181849.8095B2388AB9@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: chirino Date: Mon Dec 3 18:18:47 2012 New Revision: 1416615 URL: http://svn.apache.org/viewvc?rev=1416615&view=rev Log: Make sure we unbind producers from consumers when the producers disconnect. Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala?rev=1416615&r1=1416614&r2=1416615&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala (original) +++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Topic.scala Mon Dec 3 18:18:47 2012 @@ -563,6 +563,11 @@ class Topic(val router:LocalRouter, val for(link <- producers.remove(producer) ) { add_enqueue_counters(topic_metrics, link) } + var targets:List[DeliveryConsumer] = producer_tracker :: consumers.values.toList + if( topic_queue !=null ) { + targets ::= topic_queue + } + producer.unbind(targets) check_idle }