activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r1489485 - /activemq/trunk/activemq-broker/src/main/java/org/apache/activemq/broker/region/DestinationFilter.java
Date Tue, 04 Jun 2013 15:44:51 GMT
Author: tabish
Date: Tue Jun  4 15:44:50 2013
New Revision: 1489485

URL: http://svn.apache.org/r1489485
Log:
Fix for: https://issues.apache.org/jira/browse/AMQ-4571

accounts for nested Destination filters.

Modified:
    activemq/trunk/activemq-broker/src/main/java/org/apache/activemq/broker/region/DestinationFilter.java

Modified: activemq/trunk/activemq-broker/src/main/java/org/apache/activemq/broker/region/DestinationFilter.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-broker/src/main/java/org/apache/activemq/broker/region/DestinationFilter.java?rev=1489485&r1=1489484&r2=1489485&view=diff
==============================================================================
--- activemq/trunk/activemq-broker/src/main/java/org/apache/activemq/broker/region/DestinationFilter.java
(original)
+++ activemq/trunk/activemq-broker/src/main/java/org/apache/activemq/broker/region/DestinationFilter.java
Tue Jun  4 15:44:50 2013
@@ -389,8 +389,13 @@ public class DestinationFilter implement
     }
 
     public void deleteSubscription(ConnectionContext context, SubscriptionKey key) throws
Exception {
-        if (next instanceof Topic) {
-            ((Topic) next).deleteSubscription(context, key);
+        Destination target = next;
+        while (target instanceof DestinationFilter) {
+            target = ((DestinationFilter) target).next;
+        }
+        if (target instanceof Topic) {
+            Topic topic = (Topic)target;
+            topic.deleteSubscription(context, key);
         }
     }
 }



Mime
View raw message