public interface RemoteCacheContainer extends BasicCacheContainer
DEFAULT_CACHE_NAME
Modifier and Type | Method and Description |
---|---|
default <K,V> RemoteCache<K,V> |
getCache(boolean forceReturnValue)
Same as
getCache("", forceReturnValue, null, null) |
default <K,V> RemoteCache<K,V> |
getCache(String cacheName,
boolean forceReturnValue)
Same as
getCache(cacheName, forceReturnValue, null, null) |
default <K,V> RemoteCache<K,V> |
getCache(String cacheName,
boolean forceReturnValue,
TransactionManager transactionManager)
Same as
getCache(cacheName, forceReturnValue, null, transactionManager) |
default <K,V> RemoteCache<K,V> |
getCache(String cacheName,
boolean forceReturnValue,
TransactionMode transactionMode)
Same as
getCache(cacheName, forceReturnValue, transactionMode, null) |
<K,V> RemoteCache<K,V> |
getCache(String cacheName,
boolean forceReturnValue,
TransactionMode transactionMode,
TransactionManager transactionManager) |
default <K,V> RemoteCache<K,V> |
getCache(String cacheName,
TransactionManager transactionManager)
Same as
getCache(cacheName, null, transactionManager) |
default <K,V> RemoteCache<K,V> |
getCache(String cacheName,
TransactionMode transactionMode)
Same as
getCache(cacheName, transactionMode, null) |
<K,V> RemoteCache<K,V> |
getCache(String cacheName,
TransactionMode transactionMode,
TransactionManager transactionManager) |
Configuration |
getConfiguration()
Retrieves the configuration currently in use.
|
Marshaller |
getMarshaller() |
boolean |
isStarted() |
boolean |
switchToCluster(String clusterName)
Switch remote cache manager to a different cluster, previously
declared via configuration.
|
boolean |
switchToDefaultCluster()
Switch remote cache manager to a the default cluster, previously
declared via configuration.
|
getCache, getCache, getCacheNames
Configuration getConfiguration()
ConfigurationBuilder builder = new ConfigurationBuilder();
builder.read(remoteCacheManager.getConfiguration());
// modify builder
remoteCacheManager.stop();
remoteCacheManager = new RemoteCacheManager(builder.build());
default <K,V> RemoteCache<K,V> getCache(String cacheName, boolean forceReturnValue)
getCache(cacheName, forceReturnValue, null, null)
default <K,V> RemoteCache<K,V> getCache(boolean forceReturnValue)
getCache("", forceReturnValue, null, null)
default <K,V> RemoteCache<K,V> getCache(String cacheName, TransactionMode transactionMode)
getCache(cacheName, transactionMode, null)
default <K,V> RemoteCache<K,V> getCache(String cacheName, boolean forceReturnValue, TransactionMode transactionMode)
getCache(cacheName, forceReturnValue, transactionMode, null)
default <K,V> RemoteCache<K,V> getCache(String cacheName, TransactionManager transactionManager)
getCache(cacheName, null, transactionManager)
default <K,V> RemoteCache<K,V> getCache(String cacheName, boolean forceReturnValue, TransactionManager transactionManager)
getCache(cacheName, forceReturnValue, null, transactionManager)
<K,V> RemoteCache<K,V> getCache(String cacheName, TransactionMode transactionMode, TransactionManager transactionManager)
cacheName
- The cache's name.transactionMode
- The TransactionMode
to override. If null
, it uses the configured value.transactionManager
- The TransactionManager
to override. If null
, it uses the configured value.RemoteCache
implementation.<K,V> RemoteCache<K,V> getCache(String cacheName, boolean forceReturnValue, TransactionMode transactionMode, TransactionManager transactionManager)
cacheName
- The cache's name.forceReturnValue
- true
to force a return value when it is not needed.transactionMode
- The TransactionMode
to override. If null
, it uses the configured value.transactionManager
- The TransactionManager
to override. If null
, it uses the configured
value.RemoteCache
implementation.boolean isStarted()
boolean switchToCluster(String clusterName)
true
, otherwise it returns false
.clusterName
- name of the cluster to which to switch totrue
if the cluster was switched, false
otherwiseboolean switchToDefaultCluster()
true
, otherwise it returns false
.true
if the cluster was switched, false
otherwiseMarshaller getMarshaller()
Copyright © 2020 JBoss, a division of Red Hat. All rights reserved.