[jboss-jira] [JBoss JIRA] Created: (JBMESSAGING-1623) Client failover causes thread leak

Howard Gao (JIRA) jira-events at lists.jboss.org
Wed May 13 02:11:46 EDT 2009


Client failover causes thread leak
----------------------------------

                 Key: JBMESSAGING-1623
                 URL: https://jira.jboss.org/jira/browse/JBMESSAGING-1623
             Project: JBoss Messaging
          Issue Type: Bug
          Components: JMS Clustering
    Affects Versions: 1.4.3.GA, 1.4.2.GA.SP1, 1.4.0.SP3.CP07
            Reporter: Howard Gao
            Assignee: Howard Gao
            Priority: Critical
             Fix For: 1.4.0.SP3.CP08, 1.4.4.GA


In a clustered environment, a client failover will cause one thread leak per session, which will eventually used up system thread resources and cause outofmemory exception.

The leak happens when client failover to a new connection, the old session states will be updated to new connection, where there will be a new SessionState created for each old one. During the creation of a new SessionState, a new JBExecutor will be created in which a new thread will be created and started. But it will never use it later as the existing executor in the old state will be used. So the newly created thread has nothing to do but stay there and never exits. As more client failover happens, more such threads will be created.

The solution is simple. When the executor is created, son't start the worker thread untill it has tasks to do.


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list