Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@www.apache.org Received: (qmail 89457 invoked from network); 27 Jun 2006 18:50:08 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 27 Jun 2006 18:50:08 -0000 Received: (qmail 99669 invoked by uid 500); 27 Jun 2006 18:50:05 -0000 Delivered-To: apmail-jakarta-commons-dev-archive@jakarta.apache.org Received: (qmail 99610 invoked by uid 500); 27 Jun 2006 18:50:05 -0000 Mailing-List: contact commons-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Jakarta Commons Developers List" Reply-To: "Jakarta Commons Developers List" Delivered-To: mailing list commons-dev@jakarta.apache.org Received: (qmail 99599 invoked by uid 99); 27 Jun 2006 18:50:04 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 27 Jun 2006 11:50:04 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [209.237.227.198] (HELO brutus.apache.org) (209.237.227.198) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 27 Jun 2006 11:50:04 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id D483B7141F0 for ; Tue, 27 Jun 2006 18:48:29 +0000 (GMT) Message-ID: <29931059.1151434109867.JavaMail.jira@brutus> Date: Tue, 27 Jun 2006 18:48:29 +0000 (GMT+00:00) From: "Taras Tielkes (JIRA)" To: commons-dev@jakarta.apache.org Subject: [jira] Created: (LOGGING-108) Classloader reference leak on Tomcat 5.5.17 with log4j in webapp MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Classloader reference leak on Tomcat 5.5.17 with log4j in webapp ---------------------------------------------------------------- Key: LOGGING-108 URL: http://issues.apache.org/jira/browse/LOGGING-108 Project: Commons Logging Type: Bug Versions: 1.1 Final Environment: JDK 1.5.0_07, Tomcat 5.5.17 commons-logging-api-1.1.jar is configured for the Tomcat bootstrap commons-logging-adapters-1.1.jar is deployed with a webapp log4j-1.2.11 is deployed with webapp This is the configuration specifically described in the release notes for 1.1: " New jar file commons-logging-adapters-xxx.jar is now provided. This can be used to resolve class cast conflicts where parts of commons-logging are deployed via different classloaders. It is not expected to be frequently used; it is only necessary in situations where a container has deployed commons-logging-api.jar and a webapp wants to bind to a third-party logging implementation such as log4j. In this case, the webapp can experience problems if it deploys commons-logging.jar as this causes duplicates of the core commons-logging classes, but commons-logging-adapters can be safely used." Reporter: Taras Tielkes Some Tomcat Jasper implementation classes are initialized (that mean static fields and static initializer) when the current thread has the webapp classloader set as the context classloader. An example of this is org.apache.jasper.runtime.PageContextImpl If the first JSP page rendered on a freshly started Tomcat 5.5.17 is for a webapp that contains the configuration described in the "Environment" section above, a leak will occur: The class PageContextImpl (loader by CL above Webapp classloader in delegation chain) stays loaded for the duration of the JVM The "log" field in this class refers to a class loaded from a WebappClassloader. This produces a classloader reference leak to the webapp, even after undeployment. -- 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 --------------------------------------------------------------------- To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-dev-help@jakarta.apache.org