tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 49792] New: The clearReferencesLogFactoryRelease removes all loggers in the JVM (instead of only removing all loggers of the Web application that is being undeployed)
Date Fri, 20 Aug 2010 19:05:34 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=49792

           Summary: The clearReferencesLogFactoryRelease removes all
                    loggers in the JVM (instead of only removing all
                    loggers of the Web application that is being
                    undeployed)
           Product: Tomcat 7
           Version: 7.0.2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: regression
          Priority: P2
         Component: Catalina
        AssignedTo: dev@tomcat.apache.org
        ReportedBy: postmaster@alishomepage.com


In Tomcat 6.0.29, there's a new parameter in WebappClassLoader:
clearReferencesLogFactoryRelease

It is by default true, and executes the following code when undeploying a web
application:

        // Clear the classloader reference in common-logging
        if (clearReferencesLogFactoryRelease) {
            org.apache.juli.logging.LogFactory.release(this);
        }

The called method on JULI does the following:

        java.util.logging.LogManager.getLogManager().reset();

Which basically removes all handlers of all loggers of the Java util logger.

This cause a severe regression: all other applications in the same JVM as
Tomcat do not log anything anymore (since their handlers have disappeared).

Is this an expected behaviour? How do we tell Catalina to only remove the
handlers for the loggers by the Web application that is being undeployed?

For now, in the Tomcat integration in our application server, we have worked
around the problem by setting clearReferencesLogFactoryRelease to false. This
is of course a very bad workaround.

Cheers

S. Ali Tokmen
http://ali.tokmen.com/

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message