mirror of
https://github.com/Jetsparrow/jetherald.git
synced 2026-01-21 07:56:09 +03:00
added nlog.debug.config
This commit is contained in:
parent
9aa04ba4d7
commit
bad724e762
28
JetHerald/nlog.debug.config
Normal file
28
JetHerald/nlog.debug.config
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
autoReload="true">
|
||||||
|
|
||||||
|
<!-- enable asp.net core layout renderers -->
|
||||||
|
<extensions>
|
||||||
|
<add assembly="NLog.Web.AspNetCore"/>
|
||||||
|
</extensions>
|
||||||
|
|
||||||
|
<targets>
|
||||||
|
<target xsi:type="File" name="allfile" fileName="herald.log"
|
||||||
|
layout="${longdate}|${event-properties:item=EventId_Id}|${uppercase:${level}}|${logger}|${message} ${exception:format=tostring}" />
|
||||||
|
|
||||||
|
<target name="logconsole" xsi:type="Console"
|
||||||
|
layout="${longdate}|${level:uppercase=true}|${logger}|${message} ${exception:format=Message,StackTrace,Data:maxInnerExceptionLevel=10}"/>
|
||||||
|
</targets>
|
||||||
|
|
||||||
|
<!-- rules to map from logger name to target -->
|
||||||
|
<rules>
|
||||||
|
<!--All logs, including from Microsoft-->
|
||||||
|
<logger name="*" minlevel="Trace" writeTo="allfile" />
|
||||||
|
<logger name="*" minlevel="Trace" writeTo="logconsole" />
|
||||||
|
|
||||||
|
<!--Skip non-critical Microsoft logs and so log only own logs-->
|
||||||
|
<logger name="Microsoft.*" maxlevel="Info" final="true" />
|
||||||
|
</rules>
|
||||||
|
</nlog>
|
||||||
Loading…
Reference in New Issue
Block a user