logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Francesco Pellegrini" <f.pellegr...@telematicaitalia.it>
Subject R: File Appender help
Date Tue, 07 Dec 2004 08:41:48 GMT


Why do you want to create a separate log file for each class?  Or do you
mean that all basic classes log to one file, all servlets log to another
file, and all JSP's log to another file?  That could be achieved if your
logger naming scheme allows you to distinguish between these various
contexts.


I need to do that, because i wish to monitoring all events in my java class.
(Exception, user information and so on..).


On the chance that you simply mean not hard coding the file name in the
properties, file, here's how you reference a system property...

log4j.appender.FileLogger.File=${my_servlet_log_file_location}/Servlet.log


I tried that, but I have an error when i add one more servlet (or library
class) in my context without
created before a new /path_new_servlet/Servle.log file.
Does Log4j create dynamic  a new Appender file if it not exist in the file
system?

Thanks

Francesco.


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message