Hello,

> Thanks for your explanation about why real per-webapp logging is 
> currently not possible with Tomcat 5.5 and Juli/java.util.logging. Is it 
> the same with Log4J?
> 
Yes, naturally. You would have to place log4j.jar into your WEB-INF/lib and
the configuration into the webapp to get logger instances per webapp.
Additionally you must avoid any log4j.jar on the system/common/shared
classpath to avoid conflicts.

Again the problem: The librarys aquire a logger with the same name (usually
the package name). The webapp or classloader or any other distinct key is
not part of that. If you centraly configure "com.foo.MyClass" to log to
file1 ANY log statement of a logger with that name will log to
"com.foo.MyClass".
This is a common problem of all available logging APIs.
I fully understand your argumentation, but I think the advantage of
per-webapp logging is much more worth than "no configuration in the WAR".

If you wish to be Tomcat independent for that try:
http://www.x4juli.org
x4juli does not solve your actual problem, but is not Tomcat dependent.
Additionally it provides a native JCL implementation which is an performance
improvement.

Regards
Boris

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to