public class EhCacheRequestCache extends AbstractRequestCache
EhCache implementation of Cache
.
The configuration file is loaded using the following strategy:
cache.configuration.location
configuration
property exists and uses this path to load the file.ehcache.xml
configuration file.
Note that Dandelion uses a cache called dandelionCache
. If it doesn't
exist in your ehcache.xml
configuration file, Dandelion will
automatically add and use it.
context
DANDELION_CACHE_NAME
Constructor and Description |
---|
EhCacheRequestCache() |
Modifier and Type | Method and Description |
---|---|
void |
doClear() |
CacheEntry |
doGet(String cacheKey) |
protected Collection<CacheEntry> |
doGetAll() |
protected int |
doPut(String cacheKey,
CacheEntry cacheElement) |
String |
getCacheName() |
protected org.slf4j.Logger |
getLogger() |
void |
initCache(Context context)
Initializes the configured service provider of the
RequestCache
SPI by using the Context . |
clear, get, getAll, getGetCount, getHitCount, getMissCount, getPutCount, put
public String getCacheName()
protected org.slf4j.Logger getLogger()
getLogger
in class AbstractRequestCache
Logger
bound to the actual implementation.public void initCache(Context context)
RequestCache
Initializes the configured service provider of the RequestCache
SPI by using the Context
.
initCache
in interface RequestCache
initCache
in class AbstractRequestCache
context
- The Context
initialized in the DandelionFilter
.public CacheEntry doGet(String cacheKey)
doGet
in class AbstractRequestCache
protected int doPut(String cacheKey, CacheEntry cacheElement)
doPut
in class AbstractRequestCache
public void doClear()
doClear
in class AbstractRequestCache
protected Collection<CacheEntry> doGetAll()
doGetAll
in class AbstractRequestCache
Copyright © 2013-2015 Dandelion Project. All Rights Reserved.