activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ttmdev <>
Subject Re: how many topics can I create in a broker before getting OutOfMemoryError: Java heap space
Date Wed, 18 Jun 2008 15:37:07 GMT

I think what you're seeing is normal. Here's what I am seeing when using the

AMQ 5.1 on Windoze XP Pro using this very simple broker cfg.  

<broker brokerName="broker0" xmlns="">      
      <transportConnector name="openwire" uri="tcp://localhost:61616"/>        

After initial startup, the broker's heap usage settles down to approximately
2.1M and 19 live threads. 

I create 10 topics; each Topic invokes 3 threads (Topic, Checkpoint, and
Advisory). So with 10 new topics, I have 30 new live threads.  Heap usage
spikes to 3.3M and settles at 3.0M. 

Another 10 topics; 30 new live threads, heap usage spikes to 4.2 and settles
at around 3.9M.


Thanks Joe!

Is there any document describing how to tune ActiveMQ to be capable of
creating as many topics as needed?

basically after I create one session to the ActiveMQ and create 1750 topics,
I got the following thread information from Jconsole:
     Live Threads: 5300             Peak:5306
Daemon threads: 5292  Total started: 6424

Memory used: 170.521 kbytes

Is that normal?


ttmdev wrote:
> Not sure why you're getting the OOME even after increasing the JVM's heap
> size. But given that you're potentially creating up to 20,000 topics,
> would the use of message selectors be a more efficient approach?     
> Joe

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

View raw message