logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hugo Villeneuve <hugo.villene...@gmail.com>
Subject RollingFileAppender: Using log4j in 2 separate classpath while logging in a single file.
Date Thu, 10 Feb 2011 18:48:47 GMT

I have a different behaviour when I use DailyRollingFileAppender vs the

My setup is the following: Running in WAS (on AIX 6.1), I have 2 separate
WebApplication. Each have a Log4j Instance in their isolated classpath. Both
WebApp are configured to use a DailyRollingFileAppender to log in the SAME
file.  All this works fine (I guess under the hood, the JVM java IO are
shared across all classpath).

But the same configuration bring bizzard behaviour when switching to
RollingFileAppender + TimeBasedRollingPolicy. With the RollingFileAppender,
now I have duplicate content : Some log information is going  in the today’s
log and the same content goes in yesterdays logs.

I need advice:

1) My first reflex is to switch back to the DailyRollingFileAppender. Can
someone give me some details on the issues with this Appender.

2) How can I have 2 Separate Log4j classpath, both logging in the same file?

Thank you

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