public abstract class CommonEhCacheCacheService extends Object implements org.bonitasoft.engine.cache.CommonCacheService
| Modifier and Type | Field and Description |
|---|---|
protected Map<String,net.sf.ehcache.config.CacheConfiguration> |
cacheConfigurations |
protected net.sf.ehcache.CacheManager |
cacheManager |
protected org.bonitasoft.engine.log.technical.TechnicalLoggerService |
logger |
protected org.bonitasoft.engine.sessionaccessor.ReadSessionAccessor |
sessionAccessor |
| Constructor and Description |
|---|
CommonEhCacheCacheService(org.bonitasoft.engine.log.technical.TechnicalLoggerService logger,
org.bonitasoft.engine.sessionaccessor.ReadSessionAccessor sessionAccessor,
List<org.bonitasoft.engine.cache.CacheConfiguration> cacheConfigurations,
org.bonitasoft.engine.cache.CacheConfiguration defaultCacheConfiguration,
String diskStorePath) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
buildCacheManagerWithDefaultConfiguration() |
boolean |
clear(String cacheName) |
void |
clearAll() |
protected net.sf.ehcache.Cache |
createCache(String cacheName,
String internalCacheName) |
Object |
get(String cacheName,
Object key) |
int |
getCacheSize(String cacheName) |
protected net.sf.ehcache.config.CacheConfiguration |
getEhCacheConfiguration(org.bonitasoft.engine.cache.CacheConfiguration cacheConfig) |
protected abstract String |
getKeyFromCacheName(String cacheName) |
List<Object> |
getKeys(String cacheName) |
boolean |
isStopped() |
boolean |
remove(String cacheName,
Object key) |
protected void |
shutdownCacheManager() |
void |
store(String cacheName,
Serializable key,
Object value) |
protected net.sf.ehcache.CacheManager cacheManager
protected final org.bonitasoft.engine.log.technical.TechnicalLoggerService logger
protected final org.bonitasoft.engine.sessionaccessor.ReadSessionAccessor sessionAccessor
public CommonEhCacheCacheService(org.bonitasoft.engine.log.technical.TechnicalLoggerService logger,
org.bonitasoft.engine.sessionaccessor.ReadSessionAccessor sessionAccessor,
List<org.bonitasoft.engine.cache.CacheConfiguration> cacheConfigurations,
org.bonitasoft.engine.cache.CacheConfiguration defaultCacheConfiguration,
String diskStorePath)
protected net.sf.ehcache.config.CacheConfiguration getEhCacheConfiguration(org.bonitasoft.engine.cache.CacheConfiguration cacheConfig)
protected void buildCacheManagerWithDefaultConfiguration()
throws org.bonitasoft.engine.cache.SCacheException
org.bonitasoft.engine.cache.SCacheExceptionprotected net.sf.ehcache.Cache createCache(String cacheName, String internalCacheName) throws org.bonitasoft.engine.cache.SCacheException
org.bonitasoft.engine.cache.SCacheExceptionpublic void store(String cacheName, Serializable key, Object value) throws org.bonitasoft.engine.cache.SCacheException
store in interface org.bonitasoft.engine.cache.CommonCacheServiceorg.bonitasoft.engine.cache.SCacheExceptionprotected abstract String getKeyFromCacheName(String cacheName) throws org.bonitasoft.engine.cache.SCacheException
org.bonitasoft.engine.cache.SCacheExceptionpublic Object get(String cacheName, Object key) throws org.bonitasoft.engine.cache.SCacheException
get in interface org.bonitasoft.engine.cache.CommonCacheServiceorg.bonitasoft.engine.cache.SCacheExceptionpublic boolean clear(String cacheName) throws org.bonitasoft.engine.cache.SCacheException
clear in interface org.bonitasoft.engine.cache.CommonCacheServiceorg.bonitasoft.engine.cache.SCacheExceptionpublic int getCacheSize(String cacheName) throws org.bonitasoft.engine.cache.SCacheException
getCacheSize in interface org.bonitasoft.engine.cache.CommonCacheServiceorg.bonitasoft.engine.cache.SCacheExceptionpublic void clearAll()
throws org.bonitasoft.engine.cache.SCacheException
clearAll in interface org.bonitasoft.engine.cache.CommonCacheServiceorg.bonitasoft.engine.cache.SCacheExceptionpublic boolean remove(String cacheName, Object key) throws org.bonitasoft.engine.cache.SCacheException
remove in interface org.bonitasoft.engine.cache.CommonCacheServiceorg.bonitasoft.engine.cache.SCacheExceptionpublic List<Object> getKeys(String cacheName) throws org.bonitasoft.engine.cache.SCacheException
getKeys in interface org.bonitasoft.engine.cache.CommonCacheServiceorg.bonitasoft.engine.cache.SCacheExceptionprotected void shutdownCacheManager()
public boolean isStopped()
isStopped in interface org.bonitasoft.engine.cache.CommonCacheServiceCopyright © 2015 Bonitasoft S.A.. All rights reserved.