« Return to Thread: Seeking authoritative answer re using Log4J with v6

RE: Seeking authoritative answer re using Log4J with v6

by Jonathan Ross :: Rate this Message:

Reply to Author | View in Thread

> > I can't move log4j.jar to the system classpath, because then it
> > will be visible to all webapps

> It was already visible to all webapps when the jar was in Tomcat's lib directory, so moving it
> should not matter.  The local copies in WEB-INF/lib *should* be found before the system
> classloader is requested.  Note that in order to get individual use of log4j by a webapp,
> each must have its own log4j.jar and log4j.properties.

According to the classloader howto, the order is: system classloader, webapp classloader, common classloader.  So I'll get a global RepositorySelector if I move log4j.jar to the startup classpath.

 « Return to Thread: Seeking authoritative answer re using Log4J with v6