logger rules, level strategy?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

logger rules, level strategy?

z4711
in the NLog.config i've defined: <logger name="*" minLevel="Info" writeTo="i"/> 

usually only info-events are showed in this log
but under some circumstances (after an application exception) i got also a fatal-events in the same log, why?

what's the concept behind level?
is there some rule like  Fatal < Debug < Error < etc. ?
or if not wha't the strategy?
Reply | Threaded
Open this post in threaded view
|

Re: logger rules, level strategy?

Jason LaFlair
Administrator
With the minLevel="Info" you will get Info, Error, Warn, Fatal

http://nlog-project.org/wiki/Configuration_file#Rules

If you just want just the specific level to be logged in that rule - use level="Info"

The levels are in order of

Fatal > Error > Warn > Info > Debug > Trace