Hi

What's your system usage in conf/activemq.xml ? Are you using both
persistent and non persistent messages ?

Regards
JB

On Tue, Nov 14, 2023 at 6:45 PM CASAUX Nicolas <
nicolas.cas...@soprasteria.com> wrote:

>
> Hello,
>
> I'm facing some memory problems with ActiveMQ “Classic” with VirtualTopics
> and associated queues.
>
> My scenario is this:
>
>    - I'm using ActiveMQ 5.17.6 on Windows
>    - I'm using vanilla config (so -Xms1G -Xmx1G)
>    - I have one virtual topic VirtualTopic.test
>    - I have 3 queues associated to the topic:
>       - Consumer.a.VirtualTopic.test
>       - Consumer.b.VirtualTopic.test
>       - Consumer.c.VirtualTopic.test
>    - I publish with JMeter 2000 messages without persistence with a 25 Ko
>    payload (which represent 25 Ko * 2000 = 50 Mo of data to store in the
>    broker)
>
> Expected results:
>
>    - The 3 queues are filled with 4000 messages each.
>    - The heap used on visualVM is roughly 80Mo after GC (I assume 50 Mo
>    of message + heap required by the broker)
>    - No store or temp is used.
>    - Memory limit in the broker shows 751619277 bytes (70% of 1Go)
>
> Unexpected results:
>
>    - The MemoryPercentUsage shows 20% (which represents about 150 Mo)
>
> I guess that this 150 Mo is the total (3 * 50 Mo) of the memory used by
> the 3 queues, but they actually store 3 times the same messages. And the
> Heap usage (80 Mo) kind of proves it.
>
> The real issue is that when I publish some more messages, the broker
> considers very quickly that the memory used is falsely high, and then it
> starts some persistence mechanism. And  this problem obviously gets worst
> as I add more queues to the virtual topic.
>
> I hope it's clear enough !
>
> Thanks in advance !
>
>
> Nicolas Casaux
>
> C2 – Usage restreint
>

Reply via email to