Log4Net/C# - Disable default logging

前端 未结 2 931
庸人自扰
庸人自扰 2021-02-09 04:24

I am using log4net in a C# project, in the production environment, I want to disable all the logging, but when some fatal error occures it should log all the previous 512 messa

2条回答
  •  清酒与你
    2021-02-09 05:10

    Remove the BasicConfigurator.Configure() line. That's what that line does -- adds a ConsoleAppender pointing to Console.Out.

提交回复
热议问题