log4net - Remove old files rolling by date

后端 未结 3 1320
生来不讨喜
生来不讨喜 2020-12-28 08:44

INTENT:

a) I want my logs to be rolled by date in following file format yyyy-MM-dd.txt.

b) Additionally to this I want to remove old files which are out of

3条回答
  •  死守一世寂寞
    2020-12-28 09:06

    I spent some time looking into this a few months ago. v1.2.10 doesn't support deleting older log files based on rolling by date. It is on the task list for the next release. I took the source code and added the functionality myself, and posted it for others if they are interested. The issue and the patch can be found at https://issues.apache.org/jira/browse/LOG4NET-27 .

提交回复
热议问题