[logback-user] Rolling not working?
Henning Juva
henning.juva at gmail.com
Thu May 26 16:08:41 CEST 2011
Is rolling only triggered by an actual log event happening within the
configured timeframe and not every minute by itself?
--henning
Sent from my iPhone
On 26. mai 2011, at 15:07, Eric Pederson <ericacm at gmail.com> wrote:
> Dear all:
>
> I have the following configuration:
>
> String filename = "notification"
> appender("FILE", RollingFileAppender) {
> file = (jbossHomeDir ? jbossHomeDir + "/" : "") + "log/" + filename + ".log"
> rollingPolicy(TimeBasedRollingPolicy) {
> fileNamePattern = filename + ".%d{yyyy-MM-dd_HH-mm}.log"
> maxHistory = 30
> }
> encoder(PatternLayoutEncoder) {
> pattern = logPattern
> }
> }
>
> I have it set to roll every minute just for testing. It appears that logback is recognizing my configuration correctly:
>
> 08:55:56,095 |-INFO in ch.qos.logback.classic.gaffer.ConfigurationDelegate at 2d7d1491 - About to instantiate appender of type [ch.qos.logback.core.rolling.RollingFileAppender]
> 08:55:56,095 |-INFO in ch.qos.logback.classic.gaffer.ConfigurationDelegate at 2d7d1491 - Naming appender as [FILE]
> 08:55:56,111 |-INFO in c.q.l.core.rolling.TimeBasedRollingPolicy - No compression will be used
> 08:55:56,112 |-INFO in c.q.l.core.rolling.TimeBasedRollingPolicy - Will use the pattern notification.%d{yyyy-MM-dd_HH-mm}.log for the active file
> 08:55:56,117 |-INFO in c.q.l.core.rolling.DefaultTimeBasedFileNamingAndTriggeringPolicy - The date pattern is 'yyyy-MM-dd_HH-mm' from file name pattern 'notification.%d{yyyy-MM-dd_HH-mm}.log'.
> 08:55:56,117 |-INFO in c.q.l.core.rolling.DefaultTimeBasedFileNamingAndTriggeringPolicy - Roll-over every minute.
> 08:55:56,117 |-INFO in c.q.l.core.rolling.DefaultTimeBasedFileNamingAndTriggeringPolicy - Setting initial period to Thu May 26 08:55:27 EDT 2011
>
> However, no rolling is happening.
>
> Ideas?
>
> Thanks,
>
> -- Eric
>
> _______________________________________________
> Logback-user mailing list
> Logback-user at qos.ch
> http://qos.ch/mailman/listinfo/logback-user
More information about the Logback-user
mailing list