Package org.infinispan.globalstate
Interface LocalConfigurationStorage
-
public interface LocalConfigurationStorage
TheLocalConfigurationStorage
is responsible for applying on each node the configuration changes initiated through theGlobalConfigurationManager
and persist them unless they areCacheContainerAdmin.AdminFlag.VOLATILE
.- Since:
- 9.2
- Author:
- Tristan Tarrant
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.concurrent.CompletableFuture<java.lang.Void>
createCache(java.lang.String name, java.lang.String template, Configuration configuration, java.util.EnumSet<CacheContainerAdmin.AdminFlag> flags)
Creates the cache using the supplied template, configuration and flags.void
initialize(EmbeddedCacheManager embeddedCacheManager, ConfigurationManager configurationManager, java.util.concurrent.Executor executor)
Initialization entry point for theLocalConfigurationStorage
java.util.Map<java.lang.String,Configuration>
loadAll()
Loads all persisted cache configurationsjava.util.concurrent.CompletableFuture<java.lang.Void>
removeCache(java.lang.String name, java.util.EnumSet<CacheContainerAdmin.AdminFlag> flags)
Removes the specified cache.void
validateFlags(java.util.EnumSet<CacheContainerAdmin.AdminFlag> flags)
Checks whether thisLocalConfigurationStorage
supports the supplied flags.
-
-
-
Method Detail
-
initialize
void initialize(EmbeddedCacheManager embeddedCacheManager, ConfigurationManager configurationManager, java.util.concurrent.Executor executor)
Initialization entry point for theLocalConfigurationStorage
- Parameters:
embeddedCacheManager
-configurationManager
-executor
-
-
validateFlags
void validateFlags(java.util.EnumSet<CacheContainerAdmin.AdminFlag> flags)
Checks whether thisLocalConfigurationStorage
supports the supplied flags. ACacheConfigurationException
will be thrown in case this cannot be done.
-
createCache
java.util.concurrent.CompletableFuture<java.lang.Void> createCache(java.lang.String name, java.lang.String template, Configuration configuration, java.util.EnumSet<CacheContainerAdmin.AdminFlag> flags)
Creates the cache using the supplied template, configuration and flags. This method may be invoked either with or without a template. In both cases a concrete configuration will also be available. If a template name is present, theLocalConfigurationStorage
should use it, e.g. when persisting the configuration.- Parameters:
name
- the name of the cache to createtemplate
- the template that should be used to configure the cache. Can be null.configuration
- theConfiguration
to useflags
- the desiredCacheContainerAdmin.AdminFlag
s
-
removeCache
java.util.concurrent.CompletableFuture<java.lang.Void> removeCache(java.lang.String name, java.util.EnumSet<CacheContainerAdmin.AdminFlag> flags)
Removes the specified cache.- Parameters:
name
- the name of the cache to removeflags
- the desiredCacheContainerAdmin.AdminFlag
s
-
loadAll
java.util.Map<java.lang.String,Configuration> loadAll()
Loads all persisted cache configurations
-
-