logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bruno Melloni <Bruno.Mell...@chickasaw.net>
Subject RE: How to roll the file based on size and time?
Date Fri, 19 Feb 2010 15:07:53 GMT
I know I'll again be writing a unified DailyRollingFile/RollingFile appender for my current
job in the future.  

Is there any chance to get it included into the main distribution if I contribute it?  If
yes, what standards would it have to adhere to?

I would rather contribute it than keep rewriting it every time I change jobs.  And my current
company is probably the first that I'm working at that would not object to me contributing
a piece of code like this one even though it would be built on their clock.

b.

-----Original Message-----
From: Michael Erskine [mailto:msemtd@googlemail.com] 
Sent: Friday, February 19, 2010 8:54 AM
To: Log4J Users List
Subject: Re: How to roll the file based on size and time?

On 19 February 2010 14:08, Bruno Melloni <Bruno.Melloni@chickasaw.net> wrote:
> Indeed, I once wrote my own and it wasn't too hard.
> Still, it is surprising that an appender for such a common need was never included in
the basic set.

It is not surprising when you try to fulfil _everybody's_ needs :)

I know -- I tried -- I quit! My quicker solution was to write a little
helper class for the standard DailyRollingFileAppender that applied a
"maxBackup" property to limit the number of days' logs to be retained
to avoid disks filling up. I didn't attempt to limit the amount of
data stored in each file like the RollingFileAppender maxFileSize
property or an of the other complexities.

I shudder to think of the comprehensive unit test suite to thoroughly
validate and verify a unified DailyRollingFile/RollingFile appender.

Regards,
Michael Erskine.

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message