[logback-user] NDC?

Ceki Gulcu listid at qos.ch
Wed Sep 12 22:30:39 CEST 2007

Hello Mark,

Logback offers an alternative to log4j NDC (nested diagnostic context) with a 
similar concept called MDC (mapped diagnostic context). See 
http://logback.qos.ch/manual/mdc.html for further details.

We dropped NDC in favor of MDC because the latter is easier to manage. With MDC 
you need to manage a map instead of a stack. By the way, log4j has both NDC and MDC.


Mark Libucha wrote:
> Hi there,
> Considering a switch from log4j to logback...
> I use log4j's NDC functionality in order to be able to easily trace a
> webapp request through all levels of my code with minimal effort.
> So, why didn't NDC make it into logback, and what alternatives do I
> have for replacing NDC if I do switch to logback?
> Thanks!
> Mark
> _______________________________________________
> Logback-user mailing list
> Logback-user at qos.ch
> http://qos.ch/mailman/listinfo/logback-user

Ceki Gülcü
Logback: The reliable, generic, fast and flexible logging framework for Java.

More information about the Logback-user mailing list