[slf4j-dev] svn commit: r942 - slf4j/trunk/slf4j-jdk14/src/main/java/org/slf4j/impl

ceki at slf4j.org ceki at slf4j.org
Tue Jan 15 17:10:17 CET 2008


Author: ceki
Date: Tue Jan 15 17:10:16 2008
New Revision: 942

Modified:
   slf4j/trunk/slf4j-jdk14/src/main/java/org/slf4j/impl/StaticMDCBinder.java

Log:
- bind the MDC implementation in the jdk adapter to BasicMDCAdapter

Modified: slf4j/trunk/slf4j-jdk14/src/main/java/org/slf4j/impl/StaticMDCBinder.java
==============================================================================
--- slf4j/trunk/slf4j-jdk14/src/main/java/org/slf4j/impl/StaticMDCBinder.java	(original)
+++ slf4j/trunk/slf4j-jdk14/src/main/java/org/slf4j/impl/StaticMDCBinder.java	Tue Jan 15 17:10:16 2008
@@ -1,11 +1,11 @@
 package org.slf4j.impl;
 
-import org.slf4j.helpers.NOPMakerAdapter;
+import org.slf4j.helpers.BasicMDCAdapter;
 import org.slf4j.spi.MDCAdapter;
 
 
 /**
- * This implementation is bound to {@link NOPMakerAdapter}.
+ * This implementation is bound to {@link BasicMDCAdapter}.
  *
  * @author Ceki Gülcü
  */
@@ -22,13 +22,15 @@
   
   /**
    * Currently this method always returns an instance of 
-   * {@link StaticMDCBinder}.
+   * {@link BasicMDCAdapter}.
    */
   public MDCAdapter getMDCA() {
-     return new NOPMakerAdapter();
+    // note that this method is invoked only from within the static initializer of 
+    // the org.slf4j.MDC class.
+    return new BasicMDCAdapter();
   }
   
   public String  getMDCAdapterClassStr() {
-    return NOPMakerAdapter.class.getName();
+    return BasicMDCAdapter.class.getName();
   }
 }



More information about the slf4j-dev mailing list