activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From secondspan <>
Subject ActiveMQ 5.6 CPU steadily increases but drops at noon and midnight exactly?
Date Tue, 24 Jul 2012 20:45:14 GMT
Hi all,

We've been having a strange issue where the CPU load on our ActiveMQ server
increases continuously, only to suddenly drop off like clockwork at noon and
midnight sharp.  We are using JDK 1.7_04 with the G1 collector.

The server is receiving barely any traffic from 8pm-5am, so the CPU load
appears completely unrelated to the rate at which we process messages
through ActiveMQ.   Also, 10am-4pm is when it is processing the most
messages, so it's odd that it's at the lowest CPU usage around 12:10pm in
the middle of this peak time.

At first I suspected run-away NIO threads that are furiously polling, but it
does appear that ActiveMQ is cleaning up and constantly re-allocating new
"NIO Worker" threads and in examining their stacktrace they are all happily
spending most of their time here:

sun.misc.Unsafe.park(Native Method)

Here you can see the "Top Threads" using CPU as reported by the top threads
plug-in for JConsole.  The top threads are always mostly the "NIO Worker"

Here you can see like clockwork the CPU drops at noon and midnight.  The
23rd is the exception, where the drop-offs that didn't happen at noon and
midnight were manual restarts of the server trying various additional

For kicks, I tried the 5.7-SNAPSHOT from July 23rd.  It didn't affect the
gradual increase in CPU load.

We are using "-Dorg.apache.activemq.UseDedicatedTaskRunner=false"

Here's the line from activemq.xml where we define the transportConnector:

<transportConnector name="openwire"

I'm likely to try reverting back to BIO next as I have a hunch this might be
similar to the NIO problems that Jetty used to have back on early JDK 1.6

I figure to try the forums to see if anyone had any thoughts...


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

View raw message