activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From loamy <>
Subject Memory Leak In TransportConnector
Date Thu, 30 Jun 2011 08:44:40 GMT
Hi All

I have a Java application (A) with 4Gb of heap using an embedded broker
(v5.3.1).  I have a second application (B) also containing a broker.

Messages are sent to broker A which auto-forwards them to broker B.  We use
this setup for fault tolerance.  We want to be able to continue to run A
while B is down.  If B is down, messages are held in A until B is back up. 
This works well.

The configuration for A contains the following snippet:

        &lt;networkConnector uri=&quot;static:(tcp://&lt;B host&gt;:)"/>

I noticed recently that if B is down for an extended period of time,
application A dies with an OutOfMemoryException.

Looking at the hprof file shows that the TransportConnector class has an
enormous number of TransportConnection instances stored in a

Debugging showed that while B is down the number of TransportConnection
instances continues to climb.  It then remains static when B comes back up. 
And will again climb when B goes down.

Questions: Is this a bug?  Is there anything I can do to avoid this issue? 
Should my broker configuration/topology be different to achieve the type of
fault tolerance I'm after?

Many thanks

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

View raw message