I am using log4net to generate logs in my applicaiton. My requirement was to generate logs every minute. I have achieved this using RollingMode.Date. These files are named like: name.log.yyyyMMdd-HHmm. But my requirement is to generate开发者_如何学Python the files with name like: name.log.n where n will be sequential number. Any help??
I looked at the source code of RollingFileAppender and it seems that CountDirection=1 might be want you want.
If this does not work, I guess you need to write your own appender inheriting from RollingFileAppender which implements its own RollOverRenameFiles.
精彩评论