logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Calmus <m...@calmus.org>
Subject Re: problems with web app and JndiContextSelector
Date Fri, 01 Aug 2014 19:16:29 GMT
We're using a Servlet 2.5 container and configuration. I added the
Log4jContextSelector environment variable to the container startup as well
as loading all the Log4j 2.0 jars with the container. I added the following
items to my web.xml:




With just this, logging works fine, but I get an error when the JNDI lookup

    <description>Sets the logging context for the web-app</description>
The JNDI lookup error goes away but logging stops working.

I also tried adding the following with no change in results.

    <description>URL for configuring log4j context</description>


On Tue, Jul 29, 2014 at 11:37 AM, Ralph Goers <ralph.goers@dslextreme.com>

> The best would be a sample project that demonstrates the problem. At a
> minimum I would think the web.xml and log4j 2 configuration.
> Ralph
> On Jul 29, 2014, at 5:47 AM, Mike Calmus <mike@calmus.org> wrote:
> > I am having problems moving our web app over to Log4j 2.0 using JNDI
> > lookups. I followed the configuration documentation and am not getting
> any
> > errors, but nothing is being logged to my configured appenders. Weirdly,
> if
> > I remove the JNDI env-entry configuration from web.xml logging seems to
> > work, albeit with the expected NameNotFoundException in the server
> output.
> >
> > One possibly relevant configuration difference is that we load the log4j
> > jar files as part of server startup so each app doesn't have to load
> them.
> >
> > Any ideas? What configuration can I provide to help troubleshoot?
> >
> > Thanks.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message