cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cohei...@apache.org
Subject svn commit: r1352180 - in /cxf/trunk/rt: rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/ rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/state/ ws/security/src/main/java/org/apache/cxf/ws/security/cache/
Date Wed, 20 Jun 2012 15:59:03 GMT
Author: coheigea
Date: Wed Jun 20 15:59:03 2012
New Revision: 1352180

URL: http://svn.apache.org/viewvc?rev=1352180&view=rev
Log:
Fixing EhCache so that it picks up individual configuration properly

Modified:
    cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheTokenReplayCache.java
    cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheUtil.java
    cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/state/EHCacheSPStateManager.java
    cxf/trunk/rt/ws/security/src/main/java/org/apache/cxf/ws/security/cache/EHCacheManagerHolder.java

Modified: cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheTokenReplayCache.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheTokenReplayCache.java?rev=1352180&r1=1352179&r2=1352180&view=diff
==============================================================================
--- cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheTokenReplayCache.java
(original)
+++ cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheTokenReplayCache.java
Wed Jun 20 15:59:03 2012
@@ -42,7 +42,7 @@ public class EHCacheTokenReplayCache imp
     
     public static final long DEFAULT_TTL = 3600L;
     public static final long MAX_TTL = DEFAULT_TTL * 12L;
-    public static final String CACHE_KEY = "cxf-samlp-replay-cache";
+    public static final String CACHE_KEY = "cxf.samlp.replay.cache";
     
     private Ehcache cache;
     private CacheManager cacheManager;

Modified: cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheUtil.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheUtil.java?rev=1352180&r1=1352179&r2=1352180&view=diff
==============================================================================
--- cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheUtil.java
(original)
+++ cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/EHCacheUtil.java
Wed Jun 20 15:59:03 2012
@@ -33,7 +33,8 @@ public final class EHCacheUtil {
     public static CacheConfiguration getCacheConfiguration(String key, CacheManager cacheManager)
{
         CacheConfiguration cc = cacheManager.getConfiguration().getCacheConfigurations().get(key);
         if (cc == null && key.contains("-")) {
-            cc = cacheManager.getConfiguration().getCacheConfigurations().get(key.substring(0,
key.indexOf('-')));
+            cc = cacheManager.getConfiguration().getCacheConfigurations().get(
+                    key.substring(0, key.lastIndexOf('-') - 1));
         }
         if (cc == null) {
             cc = cacheManager.getConfiguration().getDefaultCacheConfiguration();

Modified: cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/state/EHCacheSPStateManager.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/state/EHCacheSPStateManager.java?rev=1352180&r1=1352179&r2=1352180&view=diff
==============================================================================
--- cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/state/EHCacheSPStateManager.java
(original)
+++ cxf/trunk/rt/rs/security/sso/saml/src/main/java/org/apache/cxf/rs/security/saml/sso/state/EHCacheSPStateManager.java
Wed Jun 20 15:59:03 2012
@@ -41,8 +41,8 @@ import org.apache.ws.security.util.Loade
 public class EHCacheSPStateManager implements SPStateManager {
 
     public static final long DEFAULT_TTL = 60L * 5L;
-    public static final String REQUEST_CACHE_KEY = "cxf-samlp-request-state-cache";
-    public static final String RESPONSE_CACHE_KEY = "cxf-samlp-response-state-cache";
+    public static final String REQUEST_CACHE_KEY = "cxf.samlp.request.state.cache";
+    public static final String RESPONSE_CACHE_KEY = "cxf.samlp.response.state.cache";
     
     private Ehcache requestCache;
     private Ehcache responseCache;

Modified: cxf/trunk/rt/ws/security/src/main/java/org/apache/cxf/ws/security/cache/EHCacheManagerHolder.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/security/src/main/java/org/apache/cxf/ws/security/cache/EHCacheManagerHolder.java?rev=1352180&r1=1352179&r2=1352180&view=diff
==============================================================================
--- cxf/trunk/rt/ws/security/src/main/java/org/apache/cxf/ws/security/cache/EHCacheManagerHolder.java
(original)
+++ cxf/trunk/rt/ws/security/src/main/java/org/apache/cxf/ws/security/cache/EHCacheManagerHolder.java
Wed Jun 20 15:59:03 2012
@@ -50,7 +50,8 @@ public final class EHCacheManagerHolder 
                                                            CacheManager cacheManager) {
         CacheConfiguration cc = cacheManager.getConfiguration().getCacheConfigurations().get(key);
         if (cc == null && key.contains("-")) {
-            cc = cacheManager.getConfiguration().getCacheConfigurations().get(key.substring(0,
key.indexOf('-')));
+            cc = cacheManager.getConfiguration().getCacheConfigurations().get(
+                    key.substring(0, key.lastIndexOf('-') - 1));
         }
         if (cc == null) {
             cc = cacheManager.getConfiguration().getDefaultCacheConfiguration();



Mime
View raw message