cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From owu...@apache.org
Subject svn commit: r1398813 - in /cxf/fediz/trunk/examples: simpleWebapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java wsclientWebapp/webapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
Date Tue, 16 Oct 2012 14:17:58 GMT
Author: owulff
Date: Tue Oct 16 14:17:57 2012
New Revision: 1398813

URL: http://svn.apache.org/viewvc?rev=1398813&view=rev
Log:
Fix to remove token in TLS by passing null value

Modified:
    cxf/fediz/trunk/examples/simpleWebapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
    cxf/fediz/trunk/examples/wsclientWebapp/webapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java

Modified: cxf/fediz/trunk/examples/simpleWebapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
URL: http://svn.apache.org/viewvc/cxf/fediz/trunk/examples/simpleWebapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java?rev=1398813&r1=1398812&r2=1398813&view=diff
==============================================================================
--- cxf/fediz/trunk/examples/simpleWebapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
(original)
+++ cxf/fediz/trunk/examples/simpleWebapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
Tue Oct 16 14:17:57 2012
@@ -35,7 +35,11 @@ public final class SecurityTokenThreadLo
     }    
         
     public static void setToken(Element token) {
-        TLS.set(token);
+        if (token == null) { 
+            TLS.remove();
+        } else {
+            TLS.set(token);
+        }
     }
 
     public static Element getToken() {
@@ -43,4 +47,4 @@ public final class SecurityTokenThreadLo
     }
     
 
-}
\ No newline at end of file
+}

Modified: cxf/fediz/trunk/examples/wsclientWebapp/webapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
URL: http://svn.apache.org/viewvc/cxf/fediz/trunk/examples/wsclientWebapp/webapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java?rev=1398813&r1=1398812&r2=1398813&view=diff
==============================================================================
--- cxf/fediz/trunk/examples/wsclientWebapp/webapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
(original)
+++ cxf/fediz/trunk/examples/wsclientWebapp/webapp/src/main/java/org/apache/cxf/fediz/example/SecurityTokenThreadLocal.java
Tue Oct 16 14:17:57 2012
@@ -35,7 +35,11 @@ public final class SecurityTokenThreadLo
     }    
         
     public static void setToken(Element token) {
-        TLS.set(token);
+        if (token == null) { 
+            TLS.remove();
+        } else {
+            TLS.set(token);
+        }
     }
 
     public static Element getToken() {
@@ -43,4 +47,4 @@ public final class SecurityTokenThreadLo
     }
     
 
-}
\ No newline at end of file
+}



Mime
View raw message