Package com.adaptris.core.cache.geode
Class GeodeCache
- java.lang.Object
-
- com.adaptris.core.cache.geode.GeodeCache
-
- All Implemented Interfaces:
Cache,ComponentLifecycle
public class GeodeCache extends java.lang.Object implements Cache
Interlok Apache Geode Cache Implementation.
You can configure this component via the following options:- Cache file, region name and region type
- Host, port, region name and region type
Configuration parameters:
- regionName - Name of the region where items will be cached
- hostname - geode server hostname
- port - integer, geode server port
- clientRegionShortcut - String value region type as defined:
ClientRegionShortcut - cacheFileName - String - simple file name of the geode config cache file which resides on the classpath
- isDurable - boolean - maintain your durable queues after the client cache is closed
-
-
Constructor Summary
Constructors Constructor Description GeodeCache()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclear()org.apache.geode.cache.client.ClientRegionShortcutclientRegionShortcut()voidclose()java.lang.Objectget(java.lang.String key)protected org.apache.geode.cache.Region<java.lang.String,java.lang.Object>getCache()ClientCacheBuildergetCacheBuilder()org.apache.geode.cache.client.ClientRegionShortcutgetClientRegionShortcut()java.lang.BooleangetDurable()java.lang.StringgetRegionName()voidinit()protected voidinitialiseCache()protected voidinitialiseCache(org.apache.geode.cache.client.ClientCacheFactory clientCacheFactory)voidput(java.lang.String key, java.io.Serializable value)voidput(java.lang.String key, java.lang.Object value)voidremove(java.lang.String key)voidsetCacheBuilder(ClientCacheBuilder cacheBuilder)voidsetClientRegionShortcut(org.apache.geode.cache.client.ClientRegionShortcut clientRegionShortcut)voidsetDurable(java.lang.Boolean durable)voidsetRegionName(java.lang.String regionName)intsize()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.adaptris.core.ComponentLifecycle
start, stop
-
-
-
-
Method Detail
-
init
public void init() throws CoreException- Specified by:
initin interfaceComponentLifecycle- Throws:
CoreException
-
initialiseCache
protected void initialiseCache() throws ServiceException- Throws:
ServiceException
-
initialiseCache
protected void initialiseCache(org.apache.geode.cache.client.ClientCacheFactory clientCacheFactory) throws ServiceException- Throws:
ServiceException
-
close
public void close()
- Specified by:
closein interfaceComponentLifecycle
-
put
public void put(java.lang.String key, java.io.Serializable value) throws CoreException- Specified by:
putin interfaceCache- Throws:
CoreException
-
put
public void put(java.lang.String key, java.lang.Object value) throws CoreException- Specified by:
putin interfaceCache- Throws:
CoreException
-
get
public java.lang.Object get(java.lang.String key) throws CoreException- Specified by:
getin interfaceCache- Throws:
CoreException
-
remove
public void remove(java.lang.String key) throws CoreException- Specified by:
removein interfaceCache- Throws:
CoreException
-
size
public int size() throws CoreException- Specified by:
sizein interfaceCache- Throws:
CoreException
-
clear
public void clear() throws CoreException- Specified by:
clearin interfaceCache- Throws:
CoreException
-
getCache
protected org.apache.geode.cache.Region<java.lang.String,java.lang.Object> getCache()
-
getRegionName
public java.lang.String getRegionName()
-
setRegionName
public void setRegionName(java.lang.String regionName)
-
getClientRegionShortcut
public org.apache.geode.cache.client.ClientRegionShortcut getClientRegionShortcut()
-
setClientRegionShortcut
public void setClientRegionShortcut(org.apache.geode.cache.client.ClientRegionShortcut clientRegionShortcut)
-
clientRegionShortcut
public org.apache.geode.cache.client.ClientRegionShortcut clientRegionShortcut()
-
getDurable
public java.lang.Boolean getDurable()
-
setDurable
public void setDurable(java.lang.Boolean durable)
-
getCacheBuilder
public ClientCacheBuilder getCacheBuilder()
-
setCacheBuilder
public void setCacheBuilder(ClientCacheBuilder cacheBuilder)
-
-