Hi all,
I'm facing the following problem. We have a tomcat instance with
multiple webapps. The apps share many libraries in shared/lib directory,
some of them use log4j and some apache commons-logging.
Currently all the apps log to the same log file, which is suboptimal. We
like to have one log file per webapp.
AFAIK one solution for this is to put for each webapp a log4j jar in the
WEB_INF/lib directory and a separate log4j.properties.
As far as I understand the tomcat classloader hierarchy, all libraries
in shared/lib that use log4j must then also be moved to WEB_INF/lib
directory of the webapp. (please correct me if I'm wrong!).
Unfortunately this is not possible in our specific case.
As a second solution I thought of an appender, that writes to different
files, based on the caller thread. It should be possible to extend this
to have different log files per webapp.
Has anyone already done such a thing?
Any hints how this can be easily implemented? I guess I have write a new
Appender extending AppenderSkeleton.
Thanks in advance!
Armin
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]