git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@912496 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Davies 2010-02-22 07:05:04 +00:00
parent b341d4334f
commit eb51a69c1f
1 changed files with 13 additions and 9 deletions

View File

@ -350,17 +350,21 @@ public class AdvisoryBroker extends BrokerFilter {
}
@Override
public void isFull(ConnectionContext context,Destination destination,Usage usage) {
super.isFull(context,destination, usage);
public void isFull(ConnectionContext context, Destination destination, Usage usage) {
super.isFull(context, destination, usage);
if (AdvisorySupport.isAdvisoryTopic(destination.getActiveMQDestination()) == false) {
try {
ActiveMQTopic topic = AdvisorySupport.getFullAdvisoryTopic(destination.getActiveMQDestination());
ActiveMQMessage advisoryMessage = new ActiveMQMessage();
advisoryMessage.setStringProperty(AdvisorySupport.MSG_PROPERTY_USAGE_NAME, usage.getName());
fireAdvisory(context, topic,null,null,advisoryMessage);
fireAdvisory(context, topic, null, null, advisoryMessage);
} catch (Exception e) {
LOG.warn("Failed to fire message is full advisory");
}
}
}
@Override
public void nowMasterBroker() {