activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kolton <>
Subject Multicast Discovery Agent Notifier
Date Tue, 22 Jul 2008 23:42:09 GMT

Hey all, 

     Question regarding the daemon thread "Multicast Discovery Agent
Notifier".  I've spent a fair amount of time searching for a similar issue
and looking through the source, so my apologies if this is a waste of time. 
I'm running Tomcat 2.2.26 with a Broker started via Spring using ActiveMQ
4.1.2.  Every time I execute this block of code:

     public String getMasterBrokerURL() {
		String brokerURL = "";
		try {
	  		ActiveMQConnection connection = ((ActiveMQConnection)
			if (connection.getBrokerInfo() != null) {
				brokerURL = connection.getBrokerInfo().getBrokerURL();
		} catch (JMSException e) {
                  // logging
		} catch( Throwable t){
                  // catch anything odd
		return brokerURL;

I end up with about 3 more Daemon Threads named "Multicast Discovery Agent
Notifier".  These don't appear to go away, and eventually cause a leak in
Tomcat resulting in OOM Exceptions.

Connection factory configured as follows:
     <!--  JMS Admin Service Connection -->
    <bean id="jmsStatusConnectionFactory"
    	<!-- User Name <constructor-arg ></constructor-arg>-->
    	<!-- Password <constructor-arg></constructor-arg>-->

I have added the extra parameters to the URI for debugging/testing purposes. 
I get this same behavior if I create it using only

Broker transport/network connectors (if useful):
	       <transportConnector brokerName="msBroker" name="openwire"
discoveryUri="multicast://default" uri="tcp://localhost:61616"/>
	      <networkConnector brokerName="msBroker" name="msNetworkConnetor"
networkTTL="10" failover="true" uri="multicast://default"/>

First question, is this an obviously bad way to find out who is currently
the master broker for some reason I'm missing?

Second question, am I not cleaning something up/misusing something that
results in this leak?

Or is there something more here?

Any help is greatly appreciated!



View this message in context:
Sent from the ActiveMQ - Dev mailing list archive at

View raw message