You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4net-user@logging.apache.org by Shaily Goel <gs...@novell.com> on 2005/08/17 12:52:29 UTC

DatePatterns in RollingFileAppender

Hi
 
I am using RollingFileAppender to log the messages. The
RollingFileAppender should roll the files based on Date. For this, I
need to set "DatePattern" property of RollingFileAppender. I am not able
to find the correct DatePatterns that should be used for following.
Please give me the examples that what date patterns should  I use for
following:
 
1.  Rollover at the beginning of each month
2.  Rollover at the first day of each week. The first day of the week
depends on the locale.
3.  Rollover at midnight each day 
4.  Rollover at midnight and midday of each day
5.  Rollover at the top of every hour
6.  Rollover at the beginning of every minute
 
Thanks
Shaily