You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by Vladimir Tsanev <ts...@gmail.com> on 2015/07/20 10:59:46 UTC
API for accessing the log level of appender control that was added at runtime.
Hi,
If I have configuration like
<Logger name="my.logger" />
<AppenderRef ref="appender1" level="debug" />
<AppenderRef ref="appender2" level="info" />
</Logger>
The only way to inspect what is current logging level for a give logger I
found is via LoggerCofnig#getAppenderRefs().
However if I add my logger at runtime calling
LoggerConfig loggerConfig = configuration.getLoggerConfg(loggerName);
loggerConfig.addAppender(appender, level, null);
The appenderRef collection is not updated.
Can you change the implementation so the collection is updated? or point me
to another API where I can use to inspect what is the current log level for
appender control.
Regards,
Vlado