Re: loggerContext for container shared lib

2017-10-06 Thread billok...@gmail.com
Jira ticket created: LOG4J2-2065 Thanks! Bill On 2017-10-05 06:39, Apache wrote: > As I suspected your log shows it using the wrong ClassLoader to locate the > configuration. Please create a Jira issue with this information. > > Ralph > > > On Oct 5, 2017, at 1:31 AM, "billok...@gmail.com"

Re: loggerContext for container shared lib

2017-10-05 Thread Apache
As I suspected your log shows it using the wrong ClassLoader to locate the configuration. Please create a Jira issue with this information. Ralph > On Oct 5, 2017, at 1:31 AM, "billok...@gmail.com" wrote: > > Thanks for looking into this! > > I do have a log4j2.xml in tomcat/lib, was thinking

Re: loggerContext for container shared lib

2017-10-05 Thread billok...@gmail.com
Thanks for looking into this! I do have a log4j2.xml in tomcat/lib, was thinking that would be used by the common classloader for the commomLib log... I guess the problem is that the commonLib classes were only referenced by the webapp code, thus the loggerContext for the commonLib was created

Re: loggerContext for container shared lib

2017-10-04 Thread Ralph Goers
You didn’t say if you also have a log4j2.xml file in tomcat/lib. If you log something before the two web apps start I am certain that it would use the log4j2.xml in tomcat/lib. I will have to look at the code that loads the configuration file to determine which ClassLoader it will use when the c

Re: loggerContext for container shared lib

2017-10-04 Thread billok...@gmail.com
Note: in the above example, 3 loggerContext will be created, as: - webapp1 - webapp2 - 6dde5c8d (for the commonLib that uses webapp1 log4j2.xml) - To unsubscribe, e-mail: log4j-user-unsubscr...@logging.apache.org For additional c

loggerContext for container shared lib

2017-10-04 Thread billok...@gmail.com
Hi, we have multiple webapps, say, webapp1 and webapp2, that use a shared apache lib (say commonLib, which also uses log4j logging) that deployed as jndi resource in tomcat (thus was put in tomcat/lib), and followings are our log4j jars deploy location: tomcat/lib: - log4j-core.jar, log4j-api.