tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Remy Maucherat <r...@apache.org>
Subject Re: svn commit: r531306 - in /tomcat: container/tc5.5.x/catalina/src/share/org/apache/catalina/core/ container/tc5.5.x/catalina/src/share/org/apache/catalina/session/ container/tc5.5.x/webapps/docs/ jasper/tc5.5.x/src/share/org/apache/jasper/runtime/
Date Mon, 23 Apr 2007 00:50:40 GMT
markt@apache.org wrote:
> Author: markt
> Date: Sun Apr 22 17:32:43 2007
> New Revision: 531306
> 
> URL: http://svn.apache.org/viewvc?view=rev&rev=531306
> Log:
> Fix some logging related memory leaks. This fixes 41272 and the root cause of 41939.
> 
> Modified:
>     tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java
>     tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/session/ManagerBase.java
>     tomcat/container/tc5.5.x/webapps/docs/changelog.xml
>     tomcat/jasper/tc5.5.x/src/share/org/apache/jasper/runtime/PageContextImpl.java
> 
> Modified: tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java
> URL: http://svn.apache.org/viewvc/tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java?view=diff&rev=531306&r1=531305&r2=531306
> ==============================================================================
> --- tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java
(original)
> +++ tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java
Sun Apr 22 17:32:43 2007
> @@ -168,6 +168,8 @@
>  
>          super();
>  
> +        log =  LogFactory.getLog(ApplicationDispatcher.class);
> +
>          // Save all of our configuration parameters
>          this.wrapper = wrapper;
>          this.context = (Context) wrapper.getParent();
> @@ -191,7 +193,7 @@
>  
>      // ----------------------------------------------------- Instance Variables
>  
> -    private static Log log = LogFactory.getLog(ApplicationDispatcher.class);
> +    private Log log = null;
>  
>      /**
>       * The Context this RequestDispatcher is associated with.

-1. Getting a logger has, AFAIK, a possibly significant cost. Since 
getting a RD is a very common option, this is not acceptable. If you 
really want to fix this non issue (which will simply happen elsewhere in 
more insidious form), I think you should find another way (removing a 
lot of the logging would be good, since it's lame debug which should not 
be there, and maybe use wrapper.getLogger).

Rémy

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


Mime
View raw message