You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Manfred Hantschel (JIRA)" <ax...@ws.apache.org> on 2005/09/23 14:52:27 UTC

[jira] Created: (AXIS-2229) LogFactory not released when reloading WebApp

LogFactory not released when reloading WebApp
---------------------------------------------

         Key: AXIS-2229
         URL: http://issues.apache.org/jira/browse/AXIS-2229
     Project: Apache Axis
        Type: Bug
  Components: Basic Architecture  
    Versions: 1.2.1    
 Environment: Windows XP, Tomcat 5.0.x
    Reporter: Manfred Hantschel


If you have a WebApp that contains all the axis libs in the WEB-INF/lib directory (including the commons-logging.jar) the WebAppClassLoader will not be fully removed when you stop the application.

I assume that this problem is caused by a missing LogFactory.release(). I have tried to patch the 1.2.1 version of axis by adding a destroy method to the Axis servlet that calls the release method, but that didn't hit the spot. 

You can check this url for a description: http://jakarta.apache.org/commons/logging/guide.html#Classloader%20and%20Memory%20Management

The bug is quite hard to detect. You may need a tool like JProfiler and e.g. Servlet with a static reference to itself. When Axis is loaded it registers some class outside it's own classloader, which i assume is the LogFactory. When the Webapp is stopped it usually throws the Classloader away, but the reference outside of this classloader keeps the reference and it wont get garbage collected. 


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