[logback-user] How to do this requirement

Ren, Kevin Kevin.Ren at justice.govt.nz
Mon Oct 6 02:53:36 CEST 2014


I think this TimeBaseRollingPolicy is going to backup or archive the last X days to new archive file and then the new current active log file startwith blank file.

What I want is the current active file is always keep the last X days data( for example last 7 days). chrop off the 8th back day's data.

Kevin

From: Logback-user [mailto:logback-user-bounces at qos.ch] On Behalf Of Roger Thomas
Sent: Monday, 6 October 2014 1:14 p.m.
To: logback users list
Subject: Re: [logback-user] How to do this requirement

Yes, this can be done with a TimeBasedRollingPolicy

     http://logback.qos.ch/manual/appenders.html#TimeBasedRollingPolicy

Roger

On 06/10/2014 00:20, Ren, Kevin wrote:
Hi,

Is it possible to keep the current log for last X days? archived the X+1 day back to another file.

Thanks

Kevin
________________________________

Confidentiality notice:
This email may contain information that is confidential or legally privileged. If you have received it by mistake, please:
(1) reply promptly to that effect, and remove this email and the reply from your system;
(2) do not act on this email in any other way.
Thank you.
________________________________




_______________________________________________

Logback-user mailing list

Logback-user at qos.ch<mailto:Logback-user at qos.ch>

http://mailman.qos.ch/mailman/listinfo/logback-user

------------------------------------------------------------------------------

Confidentiality notice:
This email may contain information that is confidential or legally privileged. If you have received it by mistake, please:
(1) reply promptly to that effect, and remove this email and the reply from your system;
(2) do not act on this email in any other way.
Thank you.

------------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.qos.ch/pipermail/logback-user/attachments/20141006/abe850d8/attachment-0001.html>


More information about the Logback-user mailing list