Hi!

I am trying to use an extended logkit pattern formatter with our
Fortress/DefaultContainer-based container.
However, %{method} always resolves to
"org.apache.avalon.framework.logger.LogKitLogger.debug(LogKitLogger.java:39)
".

I can see that this is because ExtendPatternFormatter#getMethod() is popping
up to "org.apache.log.Logger" from the call-stack, which still leaves
LogKitLogger on the stack above the method I am really intesrested in.

I am getting my Logger (org.apache.avalon.framework.logger.Logger) as such:

    import org.apache.avalon.excalibur.logger.LogKitLoggerManager;
    import org.apache.avalon.excalibur.logger.LoggerManager;
    import org.apache.avalon.framework.logger.Logger;

    private static Logger rootLogger = null;
    private static LoggerManager rootLoggerManager = null;
     ......
      LogKitLoggerManager tmp = new LogKitLoggerManager();
      try {
           tmp.contextualize(rootContext);
           tmp.configure(logkitConf);  // built from a logkit.xconf
     } catch .....
        ....
     }
     rootLoggerManager = tmp;
     rootLogger = rootLoggerManager.getLoggerForCategory("root");
     rootLogger.debug("......");
    .....

So, what am I doing wrong and how can I get around this problem?

Thanks,
Shash

--
To unsubscribe, e-mail:   <mailto:avalon-users-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:avalon-users-help@;jakarta.apache.org>

Reply via email to