Package org.infinispan.globalstate
Interface GlobalConfigurationManager
-
public interface GlobalConfigurationManagerTheGlobalConfigurationManageris the main interface for sharing runtime configuration state across a cluster. It uses an internal cache 'org.infinispan.CONFIG'. The cache is keyed withScopedState. Each scope owner is responsible for its own keys.- Since:
- 9.2
- Author:
- Tristan Tarrant
-
-
Field Summary
Fields Modifier and Type Field Description static StringCONFIG_STATE_CACHE_NAME
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CompletableFuture<Configuration>createCache(String cacheName, String template, EnumSet<CacheContainerAdmin.AdminFlag> flags)Defines a cluster-wide cache configuration using the supplied templateCompletableFuture<Configuration>createCache(String cacheName, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)Defines a cluster-wide cache configurationCompletableFuture<Void>createTemplate(String name, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)Defines a cluster-wide configuration templateCompletableFuture<Configuration>getOrCreateCache(String cacheName, String template, EnumSet<CacheContainerAdmin.AdminFlag> flags)Defines a cluster-wide cache configuration using the supplied template or retrieves an existing oneCompletableFuture<Configuration>getOrCreateCache(String cacheName, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)Defines a cluster-wide cache configuration or retrieves an existing oneCompletableFuture<Configuration>getOrCreateTemplate(String name, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)Defines a cluster-wide configuration templateCache<ScopedState,Object>getStateCache()Returns the global state cacheCompletableFuture<Void>removeCache(String cacheName, EnumSet<CacheContainerAdmin.AdminFlag> flags)Removes a cluster-wide cache and its configurationCompletableFuture<Void>removeTemplate(String name, EnumSet<CacheContainerAdmin.AdminFlag> flags)Removes a cluster-wide template
-
-
-
Field Detail
-
CONFIG_STATE_CACHE_NAME
static final String CONFIG_STATE_CACHE_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
getStateCache
Cache<ScopedState,Object> getStateCache()
Returns the global state cache
-
createTemplate
CompletableFuture<Void> createTemplate(String name, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Defines a cluster-wide configuration template- Parameters:
name- the name of the templateconfiguration- the configuration objectflags- the flags to apply
-
getOrCreateTemplate
CompletableFuture<Configuration> getOrCreateTemplate(String name, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Defines a cluster-wide configuration template- Parameters:
name- the name of the templateconfiguration- the configuration objectflags- the flags to apply
-
createCache
CompletableFuture<Configuration> createCache(String cacheName, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Defines a cluster-wide cache configuration- Parameters:
cacheName- the name of the configurationconfiguration- the configuration objectflags- the flags to apply
-
getOrCreateCache
CompletableFuture<Configuration> getOrCreateCache(String cacheName, Configuration configuration, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Defines a cluster-wide cache configuration or retrieves an existing one- Parameters:
cacheName- the name of the configurationconfiguration- the configuration objectflags- the flags to apply
-
createCache
CompletableFuture<Configuration> createCache(String cacheName, String template, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Defines a cluster-wide cache configuration using the supplied template- Parameters:
cacheName- the name of the configurationtemplate- the template name to useflags- the flags to apply
-
getOrCreateCache
CompletableFuture<Configuration> getOrCreateCache(String cacheName, String template, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Defines a cluster-wide cache configuration using the supplied template or retrieves an existing one- Parameters:
cacheName- the name of the configurationtemplate- the template name to useflags- the flags to apply
-
removeCache
CompletableFuture<Void> removeCache(String cacheName, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Removes a cluster-wide cache and its configuration- Parameters:
cacheName- the name of the cacheflags-
-
removeTemplate
CompletableFuture<Void> removeTemplate(String name, EnumSet<CacheContainerAdmin.AdminFlag> flags)
Removes a cluster-wide template- Parameters:
name- the name of the templateflags-
-
-