[logback-user] Choosing the right triggering and rolling policy

manoj mathai manojpmathai at gmail.com
Mon Aug 1 11:59:15 CEST 2011


I am new to logback. I am trying to configure the time and rolling policy
for a rolling file  appender.

Here's what I need:

a) Every "x" minutes, I want it to roll the file regardless of how small the
size of the live file is.(low logging rate)
b) If within those "x" minutes, the live log file size exceeds "y" KBs, i
want it to use indices like ${date_time}.0.log and ${date_time}.1.log and so
on. ( high logging rate)

I'd like "x" to be 15 mins, but if that's not doable, I can live with "x = 1

Here's my config, which doesn't seem to do exactly what I've described:

<appender name="FILE"
  <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">



Can some one help me with this ?

-- Manoj M
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://qos.ch/pipermail/logback-user/attachments/20110801/efec7b9a/attachment.html>

More information about the Logback-user mailing list