You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@excalibur.apache.org by vg...@apache.org on 2005/09/13 02:52:03 UTC

svn commit: r280457 - /excalibur/trunk/containerkit/logkit/src/java/org/apache/log/ContextMap.java

Author: vgritsenko
Date: Mon Sep 12 17:51:59 2005
New Revision: 280457

URL: http://svn.apache.org/viewcvs?rev=280457&view=rev
Log:
add removeCurrentContext() to counter getCurrentContext(); should be always
used in pair in webapps or other reloadable environment.
remove funky characters from javadoc.

Modified:
    excalibur/trunk/containerkit/logkit/src/java/org/apache/log/ContextMap.java

Modified: excalibur/trunk/containerkit/logkit/src/java/org/apache/log/ContextMap.java
URL: http://svn.apache.org/viewcvs/excalibur/trunk/containerkit/logkit/src/java/org/apache/log/ContextMap.java?rev=280457&r1=280456&r2=280457&view=diff
==============================================================================
--- excalibur/trunk/containerkit/logkit/src/java/org/apache/log/ContextMap.java (original)
+++ excalibur/trunk/containerkit/logkit/src/java/org/apache/log/ContextMap.java Mon Sep 12 17:51:59 2005
@@ -29,8 +29,8 @@
  * <li>hostname  -&gt;helm.realityforge.org</li>
  * <li>ipaddress -&gt;1.2.3.4</li>
  * <li>interface -&gt;127.0.0.1</li>
- * <li>caller � �-&gt;com.biz.MyCaller.method(MyCaller.java:18)</li>
- * <li>source � �-&gt;1.6.3.2:33</li>
+ * <li>caller    -&gt;com.biz.MyCaller.method(MyCaller.java:18)</li>
+ * <li>source    -&gt;1.6.3.2:33</li>
  * </ul>
  * The context is bound to a thread (and inherited by sub-threads) but
  * it can also be added to by LogTargets.
@@ -86,6 +86,14 @@
         }
 
         return context;
+    }
+
+    /**
+     * Remove ContextMap associated with the current thread.
+     */
+    public static void removeCurrentContext()
+    {
+        c_localContext.set( null );
     }
 
     /**



---------------------------------------------------------------------
To unsubscribe, e-mail: scm-unsubscribe@excalibur.apache.org
For additional commands, e-mail: scm-help@excalibur.apache.org