Ok, I found my mistake. I've to take the new Logger to configure from the
Hierarchy class and not from the LoggerFactory.
So the correct code is :

Hierarchy hierarchy = (Hierarchy)LogManager.GetRepository();
Logger rootLogger = hierarchy.Root;
Logger coreLogger = hierarchy.GetLogger("abc") as Logger;
RollingFileAppender roller = new RollingFileAppender();
// .... create and configure appender ...///
coreLogger.AddAppender(roller);

I hope that can be useful to other people.

Mauro


Reply via email to