mirror of
https://github.com/zhangkong828/DHTSpider.git
synced 2026-10-17 04:30:44 +08:00
60 lines
2.2 KiB
XML
60 lines
2.2 KiB
XML
<?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"
|
|
xsi:schemaLocation="http://www.nlog-project.org/schemas/NLog.xsd NLog.xsd"
|
|
autoReload="true"
|
|
throwExceptions="false"
|
|
internalLogLevel="Off" internalLogFile="c:\temp\nlog-internal.log">
|
|
|
|
<!-- optional, add some variables
|
|
https://github.com/nlog/NLog/wiki/Configuration-file#variables
|
|
-->
|
|
<variable name="myvar" value="myvalue"/>
|
|
|
|
<!--
|
|
See https://github.com/nlog/nlog/wiki/Configuration-file
|
|
for information on customizing logging rules and outputs.
|
|
-->
|
|
<targets>
|
|
|
|
<!--
|
|
add your targets here
|
|
See https://github.com/nlog/NLog/wiki/Targets for possible targets.
|
|
See https://github.com/nlog/NLog/wiki/Layout-Renderers for the possible layout renderers.
|
|
-->
|
|
|
|
<!--
|
|
Write events to a file with the date in the filename.
|
|
<target xsi:type="File" name="f" fileName="${basedir}/logs/${shortdate}.log"
|
|
layout="${longdate} ${uppercase:${level}} ${message}" />
|
|
-->
|
|
<target xsi:type="File"
|
|
name="f"
|
|
fileName="${basedir}/logs/${level}.txt"
|
|
layout="【${longdate}】 ${uppercase:${level}} ${newline} ${message} ${newline}"
|
|
archiveFileName="${basedir}/logs/${level}.{#}.log"
|
|
archiveAboveSize="1024000"
|
|
archiveNumbering ="DateAndSequence"
|
|
archiveDateFormat="yyyyMMdd"
|
|
maxArchiveFiles ="10"
|
|
/>
|
|
|
|
</targets>
|
|
|
|
<rules>
|
|
<!-- add your logging rules here -->
|
|
|
|
<!--
|
|
Write all events with minimal level of Debug (So Debug, Info, Warn, Error and Fatal, but not Trace) to "f"
|
|
<logger name="*" minlevel="Debug" writeTo="f" />
|
|
-->
|
|
<logger name="*" minlevel="Trace" writeTo="f" />
|
|
<!--<logger name="*" level="Trace" writeTo="trace_file" />
|
|
<logger name="*" level="Debug" writeTo="debug_file" />
|
|
<logger name="*" level="Info" writeTo="info_file" />
|
|
<logger name="*" level="Warn" writeTo="warn_file" />
|
|
<logger name="*" level="Error" writeTo="error_file" />
|
|
<logger name="*" level="Fatal" writeTo="fatal_file" />-->
|
|
</rules>
|
|
</nlog>
|