Class DefaultInfinispanConnectionProviderFactory
java.lang.Object
org.keycloak.connections.infinispan.DefaultInfinispanConnectionProviderFactory
- All Implemented Interfaces:
InfinispanConnectionProviderFactory,EnvironmentDependentProviderFactory,ProviderFactory<InfinispanConnectionProvider>
public class DefaultInfinispanConnectionProviderFactory
extends Object
implements InfinispanConnectionProviderFactory, EnvironmentDependentProviderFactory
- Author:
- Stian Thorgersen
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()This is called when the server shuts down.create(KeycloakSession session) getId()protected org.infinispan.configuration.cache.Configurationvoidinit(Config.Scope config) Only called once when the factory is first created.protected org.infinispan.manager.EmbeddedCacheManagerinitContainerManaged(org.infinispan.manager.EmbeddedCacheManager cacheManager) protected org.infinispan.manager.EmbeddedCacheManagerbooleanprotected voidlazyInit()voidpostInit(KeycloakSessionFactory factory) Called after all provider factories have been initializedstatic voidstatic <T> TrunWithReadLockOnCacheManager(Supplier<T> task) static voidMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.keycloak.provider.EnvironmentDependentProviderFactory
isSupportedMethods inherited from interface org.keycloak.provider.ProviderFactory
getConfigMetadata, order
-
Field Details
-
containerManaged
protected volatile boolean containerManaged
-
-
Constructor Details
-
DefaultInfinispanConnectionProviderFactory
public DefaultInfinispanConnectionProviderFactory()
-
-
Method Details
-
create
- Specified by:
createin interfaceProviderFactory<InfinispanConnectionProvider>
-
runWithReadLockOnCacheManager
-
runWithReadLockOnCacheManager
-
runWithWriteLockOnCacheManager
-
close
public void close()Description copied from interface:ProviderFactoryThis is called when the server shuts down.- Specified by:
closein interfaceProviderFactory<InfinispanConnectionProvider>
-
getId
- Specified by:
getIdin interfaceProviderFactory<InfinispanConnectionProvider>
-
init
Description copied from interface:ProviderFactoryOnly called once when the factory is first created. This config is pulled from keycloak_server.json- Specified by:
initin interfaceProviderFactory<InfinispanConnectionProvider>
-
postInit
Description copied from interface:ProviderFactoryCalled after all provider factories have been initialized- Specified by:
postInitin interfaceProviderFactory<InfinispanConnectionProvider>
-
lazyInit
protected void lazyInit() -
initContainerManaged
protected org.infinispan.manager.EmbeddedCacheManager initContainerManaged(org.infinispan.manager.EmbeddedCacheManager cacheManager) -
initEmbedded
protected org.infinispan.manager.EmbeddedCacheManager initEmbedded() -
getKeysCacheConfig
protected org.infinispan.configuration.cache.Configuration getKeysCacheConfig() -
isSupported
public boolean isSupported()- Specified by:
isSupportedin interfaceEnvironmentDependentProviderFactory- Returns:
trueif the provider is supported and should be available,falseotherwise
-