Class RemoteHttpCacheFactory
java.lang.Object
org.apache.commons.jcs3.auxiliary.AbstractAuxiliaryCacheFactory
org.apache.commons.jcs3.auxiliary.remote.http.client.RemoteHttpCacheFactory
- All Implemented Interfaces:
AuxiliaryCacheFactory
The RemoteCacheFactory creates remote caches for the cache hub. It returns a no wait facade which
is a wrapper around a no wait. The no wait object is either an active connection to a remote
cache or a balking zombie if the remote cache is not accessible. It should be transparent to the
clients.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<K,
V> AuxiliaryCache<K, V> createCache
(AuxiliaryCacheAttributes iaca, ICompositeCacheManager cacheMgr, ICacheEventLogger cacheEventLogger, IElementSerializer elementSerializer) For LOCAL clients we get a handle to all the failovers, but we do not register a listener with them.protected <V,
K> IRemoteHttpCacheClient<K, V> This is an extension point.void
dispose()
Dispose of this factory, clean up shared resourcesvoid
Initialize this factoryMethods inherited from class org.apache.commons.jcs3.auxiliary.AbstractAuxiliaryCacheFactory
getName, setName
-
Constructor Details
-
RemoteHttpCacheFactory
public RemoteHttpCacheFactory()
-
-
Method Details
-
createCache
public <K,V> AuxiliaryCache<K,V> createCache(AuxiliaryCacheAttributes iaca, ICompositeCacheManager cacheMgr, ICacheEventLogger cacheEventLogger, IElementSerializer elementSerializer) For LOCAL clients we get a handle to all the failovers, but we do not register a listener with them. We create the RemoteCacheManager, but we do not get a cache.The failover runner will get a cache from the manager. When the primary is restored it will tell the manager for the failover to deregister the listener.
- Parameters:
iaca
-cacheMgr
-cacheEventLogger
-elementSerializer
-- Returns:
- AuxiliaryCache
-
createRemoteHttpCacheClientForAttributes
protected <V,K> IRemoteHttpCacheClient<K,V> createRemoteHttpCacheClientForAttributes(RemoteHttpCacheAttributes cattr) This is an extension point. The manager and other classes will only create RemoteHttpCacheClient through this method.- Parameters:
cattr
- the cache configuration- Returns:
- the client instance
-
initialize
Description copied from interface:AuxiliaryCacheFactory
Initialize this factory- See Also:
-
dispose
Description copied from interface:AuxiliaryCacheFactory
Dispose of this factory, clean up shared resources- See Also:
-