From 99c2b2e2d2767ee81ca0f3551299f436a289fa18 Mon Sep 17 00:00:00 2001 From: "Timothy A. Bish" Date: Tue, 29 Jan 2013 17:36:26 +0000 Subject: [PATCH] fix for: https://issues.apache.org/jira/browse/AMQ-4282 Make sure that we don't allow advisory destinations to be marked as sync dispatch. git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1440018 13f79535-47bb-0310-9956-ffa450edef68 --- .../activemq/network/DemandForwardingBridgeSupport.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/activemq-broker/src/main/java/org/apache/activemq/network/DemandForwardingBridgeSupport.java b/activemq-broker/src/main/java/org/apache/activemq/network/DemandForwardingBridgeSupport.java index 5ab610bce8..2ed025235a 100644 --- a/activemq-broker/src/main/java/org/apache/activemq/network/DemandForwardingBridgeSupport.java +++ b/activemq-broker/src/main/java/org/apache/activemq/network/DemandForwardingBridgeSupport.java @@ -1332,7 +1332,11 @@ public abstract class DemandForwardingBridgeSupport implements NetworkBridge, Br } protected void configureDemandSubscription(ConsumerInfo info, DemandSubscription sub) throws IOException { - sub.getLocalInfo().setDispatchAsync(configuration.isDispatchAsync()); + if (AdvisorySupport.isConsumerAdvisoryTopic(info.getDestination())){ + sub.getLocalInfo().setDispatchAsync(true); + } else { + sub.getLocalInfo().setDispatchAsync(configuration.isDispatchAsync()); + } sub.getLocalInfo().setPrefetchSize(configuration.getPrefetchSize()); subscriptionMapByLocalId.put(sub.getLocalInfo().getConsumerId(), sub); subscriptionMapByRemoteId.put(sub.getRemoteInfo().getConsumerId(), sub);