Tomcat6 ignores logging.properties partially

Posted by Bob on Stack Overflow See other posts from Stack Overflow or by Bob
Published on 2010-06-08T22:09:56Z Indexed on 2010/06/08 22:12 UTC
Read the original article Hit count: 389

I'm using Tomcat 6, and this is my logging.properties:

handlers = org.apache.juli.FileHandler, java.util.logging.ConsoleHandler
.level=FINE

org.apache.catalina.core.ApplicationContext.level = OFF

org.apache.juli.FileHandler.level = ALL
org.apache.juli.FileHandler.directory = ${catalina.base}/logs
org.apache.juli.FileHandler.prefix = mylog.

java.util.logging.ConsoleHandler.level = FINE
java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter

On the one hand, Tomcat seems to read this file, as it correctly saves the logfiles with the prefix "mylog" and prints only messages with log-level FINE and above. On the other hand, it keeps on writing log messages like this:

Jun 8, 2010 9:53:30 PM org.apache.catalina.core.ApplicationContext log
SEVERE: Error writing messages
ClientAbortException:  java.net.SocketException: Broken pipe

I actually wanted to suppress all log messages from this class, as they flood my logfile, and the error is irrelevant for me. So why is the following line ignored?

org.apache.catalina.core.ApplicationContext.level = OFF

Is there any other way to suppress the log output of this class?

© Stack Overflow or respective owner

Related posts about tomcat

Related posts about logging