logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ceki Gülcü <...@qos.ch>
Subject Re: daily log file question (code submission)
Date Tue, 21 Aug 2001 20:02:19 GMT

Don,

Well done!

I would have preferred to see the original author names be retained but that is is easy enough
to remedy. Thanks for your contribution. Ceki

At 19:20 12.08.2001 -0700, Don Taylor wrote:
>Attached is a jar file containing
>org.apache.log4j.DailyRollingFileAppenderExt addressing the five points
>I mentioned below. The source and javadoc is also in the jar. To use,
>you can simply mount the jar.
>
>I want to work on a version that would make point 2 optional, i.e. to
>allow functionality like DailyRollingFileAppender.
>
>Enjoy.
>
>-- Don
>
>--- Ceki Gülcü <cgu@qos.ch> wrote:
>> At 09:31 08.08.2001 -0700, Don Taylor wrote:
>> >--- Aron Kramlik <aron.kramlik@itouch.com.au> wrote:
>> >> Hi,
>> >> 
>> >> I would like to ask if the DailyRollingFileAppender is the class
>> that
>> >> is
>> >> meant to be used for log files that need to be rolled every day.
>> >
>> >It is.
>> >
>> >> I have seen some discussion in the archives and I am not sure it
>> >> is production ready from the discussions - could you please advise
>> >> if this is considered ready to be used in production?  Also, a
>> simple
>> >> example, or pointer to an example, of how one can go about using
>> it.
>> >> 
>> >> Thanks,
>> >> 
>> >> Aron Kramlik
>> >> aron.kramlik@itouch.com.au
>> >> 
>> >
>> >Most of the discussion involves it not working the way you really
>> want.
>> >I have a version that's in production that does what most people
>> want,
>> >but it's only been in production a couple of weeks. I'm planning on
>> >posting it to the group this weekend, after it's cleaned-up some
>> >(getting it up to the coding standards, placing it in the right
>> >package, and so on.) In the meantime, go ahead and use the existing
>> >DailyRollingFileAppender.
>> >
>> >The problems my version resolves:
>> >
>> >1. DailyRollingFileAppender will not rollover the log file if the
>> >application isn't running at the time of the rollover.
>> >
>> >(Actually, a fix to this has already been posted. I've just
>> >incorporated it in my version.)
>> 
>> Good.
>> 
>> >2. DailyRollingFileAppender does not use the date/time stamp in the
>> >file name for the currently active logging file.
>> 
>> Yes, this was suggested as a change. However, some users need the
>> behavior to remain the same.
>> 
>> >3. DailyRollingFileAppender always appends the date/time stamp to
>> the
>> >filename, rather than determining if an extension exists and
>> inserting
>> >the date/time stamp just before the extension. This really helps
>> when
>> >viewing the log file in extension-oriented systems such as Windows.
>> 
>> Makes sense.
>> 
>> >4. DailyRollingFileAppender does not limit the maximum number of
>> logs
>> >that can be created. It'll create logs forever. My version does the
>> >same thing, but you can optionally set a limit. (You can't limit the
>> >size, only the number.)
>> 
>> Seems reasonable.
>> 
>> >5. DailyRollingFileAppender doesn't work well with layouts such as
>> >HTMLLayout. Everytime you start a logging session a header is sent
>> to
>> >the log. That makes an HTML file a mess. My version allows you to
>> >specify how to handle the header when appending to an
>> already-existing
>> >log.
>> 
>> Good point.
>> 
>> >Is DailyRollingFileAppender ready for production? Sure, just pay
>> >attention to the caveats. If you're interested in my version, give
>> me a
>> >couple of days to clean it up and get it posted. In the meantime,
>> just
>> >use DailyRollingFileAppender.
>> 
>> Please post it when you are done. Ceki
>> 
>> --
>> Ceki Gülcü - http://qos.ch
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: log4j-user-help@jakarta.apache.org
>> 
>
>
>__________________________________________________
>Do You Yahoo!?
>Send instant messages & get email alerts with Yahoo! Messenger.
>http://im.yahoo.com/
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: log4j-user-help@jakarta.apache.org

--
Ceki Gülcü - http://qos.ch


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


Mime
View raw message