metatech created AMQ-4790:
-----------------------------

             Summary: Avoid thread creation storm after machine suspend/resume
                 Key: AMQ-4790
                 URL: https://issues.apache.org/jira/browse/AMQ-4790
             Project: ActiveMQ
          Issue Type: Bug
          Components: Broker
    Affects Versions: 5.5.1
         Environment: ServiceMix 4.4.2
            Reporter: metatech
            Priority: Minor


My ActiveMQ broker is running and I suspend my PC.  When I resume the machine 
the next day or (much worse) after a week-end, my PC is busy at 100% CPU for a 
few minutes.  Because many threads are busy in parallel, the PC is completely 
unresponsive and the even the mouse cursor can hardly move.
I had noticed that it only happens when my ServiceMix is started, and when the 
embedded ActiveMQ broker is configured with a JDBC persistence adapter.
After investigating in the code, I found out that the "lock keep alive" feature 
uses the "scheduleWithFixedDelay" to update a DB lock every 30 seconds.  When 
the PC is resumed, this generates a "backlog" of thousands of calls.  It is 
better to use "scheduleWithFixedDelay" instead, which waits until the previous 
calls has finished before firing a new one.




--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to