I want to create Handler that will be catch all Logs of web aplications on Tomcat,
I Created my Handler class, compiled it and put on $CATALINA_HOME/lib
, and common.loader
has this directory. After this I modified the logging.properties
file and added the handler:
handlers = 1catalina.org.apache.juli.FileHandler, 2localhost.org.apache.juli.FileHandler, 3manager.org.apache.juli.FileHandler, 4host-manager.org.apache.juli.FileHandler, java.util.logging.ConsoleHandler, logshowaplication.ErrorsListHandler
I put some filestream, and when object Handler created, it will write some message in file.
and there aren't mistakes when I run tomcat, but when I run it, this message isn't appear in file, therefore Handler object not creates. I'm new in Java and ask you for help. sorry for bad English.