我是否在这里看到了ug,或者我是否对这一组合做了一些错误?
<appender name="ConsoleAppender" type="log4net.Appender.ConsoleAppender">
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="%message%newline" />
</layout>
</appender>
<logger name="MyApp.Common">
<level value="WARN" />
<appender-ref ref="ConsoleAppender" />
</logger>
<logger name="MyApp.Common.Namespace.SomeGenericClass`1">
<level value="INFO" />
<appender-ref ref="ConsoleAppender" />
</logger>
假设我按照标准“......DeclaringType”命名计划命名我的记录仪,我在此期望的是,我的评估书规定的所有事项。 共同名称空间只要带上WARN或更高名称,就将进入该群岛。 某些基因组别的1号中的任何数据,如果其信息或更高(如果由于WARN的记录,其数据为WARN或更高两次)。
What is happening is that anything in SomeGenericClass`1 that gets logged in INFO will be piped out to the console twice, instead of the expected once. If I remove the more specific logger, nothing gets logged, and if I remove the less specific logger, things only log once, both as expected. In addition, reversing the order of the loggers in the config file does nothing (as I would expect, since I would guess that order doesn t matter).
Did I find a bug here, or am I missing something important in how the hierarchy works?