Example usage for org.apache.shiro.cache.ehcache EhCacheManager setCacheManagerConfigFile

List of usage examples for org.apache.shiro.cache.ehcache EhCacheManager setCacheManagerConfigFile

Introduction

In this page you can find the example usage for org.apache.shiro.cache.ehcache EhCacheManager setCacheManagerConfigFile.

Prototype

public void setCacheManagerConfigFile(String classpathLocation) 

Source Link

Document

Sets the resource location of the config file used to initialize the wrapped EhCache CacheManager instance.

Usage

From source file:com.smile.core.shiro.configuration.ShiroConfiguration.java

License:Apache License

@Bean
protected CacheManager cacheManager() {
    EhCacheManager ehCacheManager = new EhCacheManager();
    ehCacheManager.setCacheManagerConfigFile("classpath:ehcache.xml");
    return ehCacheManager;
}

From source file:com.whatlookingfor.sample.config.ShiroConfiguration.java

License:Apache License

@Bean(name = "cacheManager")
public EhCacheManager cacheManager() {
    EhCacheManager ehCacheManager = new EhCacheManager();
    ehCacheManager.setCacheManagerConfigFile("classpath:cache/ehcache-local.xml");
    return ehCacheManager;
}