import net.sf.ehcache.CacheManager;
import net.sf.ehcache.Element;
import net.sf.ehcache.config.CacheConfiguration;
+import net.sf.ehcache.config.Configuration;
+import net.sf.ehcache.config.ConfigurationFactory;
import org.opendaylight.aaa.api.model.User;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
// When we restart, the cache manager and CLI cache are already there
CacheManager cm = CacheManager.getCacheManager(CLI_CACHE_MANAGER);
if (cm == null) {
+ Configuration configuration = ConfigurationFactory.parseConfiguration();
+ configuration.setName(CLI_CACHE_MANAGER);
cm = CacheManager.newInstance();
- cm.setName(CLI_CACHE_MANAGER);
}
Cache existingCache = cm.getCache(CLI_CACHE);
if (existingCache != null) {
import net.sf.ehcache.CacheManager;
import net.sf.ehcache.Element;
import net.sf.ehcache.config.CacheConfiguration;
+import net.sf.ehcache.config.Configuration;
+import net.sf.ehcache.config.ConfigurationFactory;
import org.opendaylight.aaa.api.Authentication;
import org.opendaylight.aaa.api.TokenStore;
import org.slf4j.Logger;
// When we restart, the cache manager and token cache are already there
CacheManager cm = CacheManager.getCacheManager(TOKEN_CACHE_MANAGER);
if (cm == null) {
- cm = CacheManager.newInstance();
- cm.setName(TOKEN_CACHE_MANAGER);
+ Configuration configuration = ConfigurationFactory.parseConfiguration();
+ configuration.setName(TOKEN_CACHE_MANAGER);
+ cm = CacheManager.newInstance(configuration);
}
Cache existingCache = cm.getCache(TOKEN_CACHE);
if (existingCache != null) {
<dependency>
<groupId>net.sf.ehcache</groupId>
<artifactId>ehcache</artifactId>
- <version>2.8.3</version>
+ <version>2.10.6</version>
</dependency>
<dependency>
<groupId>org.apache.oltu.oauth2</groupId>