Has anyone successfully used TimeBasedRollingPolicy? Would you be
willing to share a working configuration? If I don't resolve this
today, I'll revert to DailyRollingFileAppender and cron jobs to do the
compression, a significantly less appetizing approach.
Thanks,
Tony
On Oct 17, 2008, at 10:33 AM, Tony Payne wrote:
Here is my configuration:
<appender name="RA"
class="org.apache.log4j.rolling.RollingFileAppender">
<param name="Append" value="true"/>
<rollingPolicy
class="org.apache.log4j.rolling.TimeBasedRollingPolicy">
<param name="FileNamePattern" value="__LOCAL_VAR__/logs/
%d{yyyy/MM/dd/'race'-yyyyMMddHH}.log.gz"/>
</rollingPolicy>
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d{ISO8601}\t%m%n"/>
</layout>
</appender>
This works fine during the day, rolling over at the top of the hour
and compressing the older file. However, at midnight, it stops rolling
over and all subsequent messages go to the last active log name. Is
there something wrong with my configuration?
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]