Class DefaultCacheEmbeddedConfigProviderFactory
java.lang.Object
org.keycloak.spi.infinispan.impl.embedded.DefaultCacheEmbeddedConfigProviderFactory
- All Implemented Interfaces:
Provider,ProviderFactory<CacheEmbeddedConfigProvider>,CacheEmbeddedConfigProvider,CacheEmbeddedConfigProviderFactory
public class DefaultCacheEmbeddedConfigProviderFactory
extends Object
implements CacheEmbeddedConfigProviderFactory, CacheEmbeddedConfigProvider
The default implementation of
CacheEmbeddedConfigProviderFactory.
It builds a ConfigurationBuilderHolder based on the Keycloak configuration.
Advanced users may extend this class and overwrite the method createConfiguration(KeycloakSessionFactory).
They have access to the ConfigurationBuilderHolder, and they can modify it as needed for their custom
providers.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()This is called when the server shuts down.org.infinispan.configuration.parsing.ConfigurationBuilderHolderTheConfigurationBuilderHolderwhit theEmbeddedCacheManagerconfiguration.create(KeycloakSession session) protected org.infinispan.configuration.parsing.ConfigurationBuilderHolderOptional method used to declare that a ProviderFactory has a dependency on one or more Providers.Returns the metadata for each configuration property supported by this factory.getId()voidinit(Config.Scope config) Only called once when the factory is first created.voidpostInit(KeycloakSessionFactory factory) Called after all provider factories have been initializedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.keycloak.provider.ProviderFactory
order
-
Field Details
-
PROVIDER_ID
- See Also:
-
CONFIG
- See Also:
-
CONFIG_MUTATE
- See Also:
-
TRACING
- See Also:
-
STACK
- See Also:
-
NODE_NAME
- See Also:
-
SITE_NAME
- See Also:
-
MACHINE_NAME
- See Also:
-
RACK_NAME
- See Also:
-
-
Constructor Details
-
DefaultCacheEmbeddedConfigProviderFactory
public DefaultCacheEmbeddedConfigProviderFactory()
-
-
Method Details
-
create
- Specified by:
createin interfaceProviderFactory<CacheEmbeddedConfigProvider>
-
init
Description copied from interface:ProviderFactoryOnly called once when the factory is first created.- Specified by:
initin interfaceProviderFactory<CacheEmbeddedConfigProvider>
-
postInit
Description copied from interface:ProviderFactoryCalled after all provider factories have been initialized- Specified by:
postInitin interfaceProviderFactory<CacheEmbeddedConfigProvider>
-
configuration
public org.infinispan.configuration.parsing.ConfigurationBuilderHolder configuration()Description copied from interface:CacheEmbeddedConfigProviderTheConfigurationBuilderHolderwhit theEmbeddedCacheManagerconfiguration. It must not benull.- Specified by:
configurationin interfaceCacheEmbeddedConfigProvider- Returns:
- The
ConfigurationBuilderHolderwhit theEmbeddedCacheManagerconfiguration.
-
close
public void close()Description copied from interface:ProviderFactoryThis is called when the server shuts down.- Specified by:
closein interfaceCacheEmbeddedConfigProvider- Specified by:
closein interfaceProvider- Specified by:
closein interfaceProviderFactory<CacheEmbeddedConfigProvider>
-
getId
- Specified by:
getIdin interfaceProviderFactory<CacheEmbeddedConfigProvider>
-
getConfigMetadata
Description copied from interface:ProviderFactoryReturns the metadata for each configuration property supported by this factory.- Specified by:
getConfigMetadatain interfaceProviderFactory<CacheEmbeddedConfigProvider>- Returns:
- a list with the metadata for each configuration property supported by this factory
-
dependsOn
Description copied from interface:ProviderFactoryOptional method used to declare that a ProviderFactory has a dependency on one or more Providers. If a Provider is declared here, it is guaranteed that the dependenciesProviderFactory.postInit(org.keycloak.models.KeycloakSessionFactory)method will be executed before this ProviderFactory'sProviderFactory.postInit(org.keycloak.models.KeycloakSessionFactory). Similarly, it's guaranteed thatProviderFactory.close()will be called on thisProviderFactorybeforeProviderFactory.close()is called on any of the dependent ProviderFactory implementations.- Specified by:
dependsOnin interfaceProviderFactory<CacheEmbeddedConfigProvider>
-
createConfiguration
protected org.infinispan.configuration.parsing.ConfigurationBuilderHolder createConfiguration(KeycloakSessionFactory factory) throws IOException - Throws:
IOException
-