vmasina wrote:
> 
> We are using springframework 2.0.x jms remoting (request/response) and
> Activemq 4.1.2 which is creating lot of advisory topics, which in turning
> causing memory after performing 2-3k request/reponse calls. Upon further
> investigation found that spring jms remoting uses temporary queues for
> each request/reply call and ActiveMQ is creating many Advisory
> topics/messages which is causing the memory leak. We tried by disabling
> the Adivisory messages but this is causing temporary queues to fail.
> 
> I am wondering what is the solution for this. 
> 
> How can we disable adivisory messages when using temporary queues?
> How can we make ActiveMQ cleanup the Advisory messages? 
> 
> Is this issue something related to the configuration of ActiveMQ?
> 
> We observed similar issue in 5.1.x
> 

I had similar issues when not deleting the temporary queue explicitly and
relying on closing the session that created the queue. 

Javadoc of "createTemporaryQueue()" says:
    "Creates a TemporaryQueue object. Its lifetime will be that of the
QueueConnection unless it is deleted earlier. "
... so the queue should be deleted by the JMS provider, when the session is
closed.

The current development version behaves better. Apparently it is being
solved.


I noticed it, because the number of threads increased by three for every
temporary queue. After a few hundred we've got an OutOfMemoryError, not
because of main memory, but because each thread needs special memory (stack,
etc).

I've made a test app (both for JBoss and stand-alone) that demonstrates it.

See
  https://issues.apache.org/activemq/browse/AMQ-1849

Hans
-- 
View this message in context: 
http://www.nabble.com/temp-queues-and-advisory-messages----memory-leaks-tp18577957p18578197.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to