My reading of your configuration indicates that you're actually creating the 
extra queue yourself.  When you configure a JMS queue like this:

   <jms xmlns="urn:activemq:jms">
      <queue name="interServerQueue"/>      

This gets turned into a core queue named "jms.queue.interServerQueue" mapped to 
an core address also named "jms.queue.interServerQueue".  So that's queue #1.

When you configure a core queue like this:

   <queue name="interServerQueue">

This creates a core queue name "interServerQueue" mapped to a core address 
named "jms.queue.interServerQueue".  That's queue #2.

Since both queue #1 and #2 are mapped to the same address (i.e. 
"jms.queue.interServerQueue") they will both get all the same messages.  
However, my guess is that your application is only consuming messages from 
queue #1 (i.e. the "JMS" queue) which means messages build up in queue #2 since 
there's no client to consume them.

Ultimately I think this is a misconfiguration.  Remove the core queue you've 
configured and see how it goes.


----- Original Message -----
From: "mcacker" <>
Sent: Thursday, September 22, 2016 12:53:18 PM
Subject: Potential memory leak with local queue consumer


I have a scenario where I have a queue, interServerQueue, for which I create
a local connection and consumer.  The queue is sent messages by local and
remote producers.  Messages sent to the queue are received and processed by
the local consumer.

A heap dump, however, shows 2 QueueImpl objects, one with a consumer and one
without.  The one with a consumer has retained no messages in the
messageReferences queue, whereas the one without the consumer is
accumulating messages, and it doesn't look like they are ever getting
cleaned up.

I'm concerned that this is a memory leak, and is very similar (a QueueImpl
without a consumer) to that reported in

My configuration:

<configuration xmlns:xsi="";
               xsi:schemaLocation="urn:activemq /schema/artemis-server.xsd">

   <jms xmlns="urn:activemq:jms">

            <topic name="asyncEvents"/>
            <queue name="interServerQueue"/>
                <topic name="notificationsTopic"/>
   <core xmlns="urn:activemq:core">

                        <queue name="interServerQueue">
                        <connector name="in-vm">vm://0</connector>
                        <acceptor name="in-vm">vm://0</acceptor>
                        <acceptor name="netty">tcp://</acceptor>




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

Reply via email to