Package org.keycloak.models.map.lock
Class MapGlobalLockProviderFactory
- java.lang.Object
-
- org.keycloak.models.map.common.AbstractMapProviderFactory<GlobalLockProvider,MapLockEntity,MapLockEntity>
-
- org.keycloak.models.map.lock.MapGlobalLockProviderFactory
-
- All Implemented Interfaces:
AmphibianProviderFactory<GlobalLockProvider>
,ComponentFactory<GlobalLockProvider,GlobalLockProvider>
,GlobalLockProviderFactory
,ConfiguredProvider
,EnvironmentDependentProviderFactory
,ProviderFactory<GlobalLockProvider>
public class MapGlobalLockProviderFactory extends AbstractMapProviderFactory<GlobalLockProvider,MapLockEntity,MapLockEntity> implements GlobalLockProviderFactory, EnvironmentDependentProviderFactory
Factory to create a GlobalLockProvider backed by a Map store.- Author:
- Alexander Schwartz
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.keycloak.models.map.common.AbstractMapProviderFactory
AbstractMapProviderFactory.MapProviderObjectType
-
-
Field Summary
Fields Modifier and Type Field Description static String
DEFAULT_TIMEOUT_MILLISECONDS
static long
DEFAULT_VALUE
-
Fields inherited from class org.keycloak.models.map.common.AbstractMapProviderFactory
CONFIG_STORAGE, LOG, modelType, PROVIDER_ID, uniqueCounter
-
-
Constructor Summary
Constructors Constructor Description MapGlobalLockProviderFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
This is called when the server shuts down.MapGlobalLockProvider
createNew(KeycloakSession session)
Creates new instance of a provider.List<ProviderConfigProperty>
getConfigMetadata()
Returns the metadata for each configuration property supported by this factory.String
getHelpText()
String
getId()
void
init(Config.Scope config)
Only called once when the factory is first created.boolean
isSupported()
void
postInit(KeycloakSessionFactory factory)
Called after all provider factories have been initialized-
Methods inherited from class org.keycloak.models.map.common.AbstractMapProviderFactory
create, getMapStorage, getProviderFactoryOrComponentFactory
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.keycloak.component.AmphibianProviderFactory
create, getConfigProperties, onUpdate, preRemove
-
Methods inherited from interface org.keycloak.component.ComponentFactory
getCommonProviderConfigProperties, getTypeMetadata, onCreate, validateConfiguration
-
Methods inherited from interface org.keycloak.provider.ConfiguredProvider
getConfig
-
Methods inherited from interface org.keycloak.provider.EnvironmentDependentProviderFactory
isSupported
-
Methods inherited from interface org.keycloak.provider.ProviderFactory
order
-
-
-
-
Field Detail
-
DEFAULT_TIMEOUT_MILLISECONDS
public static final String DEFAULT_TIMEOUT_MILLISECONDS
- See Also:
- Constant Field Values
-
DEFAULT_VALUE
public static final long DEFAULT_VALUE
- See Also:
- Constant Field Values
-
-
Method Detail
-
createNew
public MapGlobalLockProvider createNew(KeycloakSession session)
Description copied from class:AbstractMapProviderFactory
Creates new instance of a provider.- Specified by:
createNew
in classAbstractMapProviderFactory<GlobalLockProvider,MapLockEntity,MapLockEntity>
- Returns:
- See description.
-
init
public void init(Config.Scope config)
Description copied from interface:ProviderFactory
Only called once when the factory is first created. This config is pulled from keycloak_server.json- Specified by:
init
in interfaceProviderFactory<GlobalLockProvider>
- Overrides:
init
in classAbstractMapProviderFactory<GlobalLockProvider,MapLockEntity,MapLockEntity>
-
postInit
public void postInit(KeycloakSessionFactory factory)
Description copied from interface:ProviderFactory
Called after all provider factories have been initialized- Specified by:
postInit
in interfaceProviderFactory<GlobalLockProvider>
- Overrides:
postInit
in classAbstractMapProviderFactory<GlobalLockProvider,MapLockEntity,MapLockEntity>
-
close
public void close()
Description copied from interface:ProviderFactory
This is called when the server shuts down.- Specified by:
close
in interfaceAmphibianProviderFactory<GlobalLockProvider>
- Specified by:
close
in interfaceProviderFactory<GlobalLockProvider>
-
getId
public String getId()
- Specified by:
getId
in interfaceProviderFactory<GlobalLockProvider>
- Overrides:
getId
in classAbstractMapProviderFactory<GlobalLockProvider,MapLockEntity,MapLockEntity>
-
isSupported
public boolean isSupported()
- Specified by:
isSupported
in interfaceEnvironmentDependentProviderFactory
- Overrides:
isSupported
in classAbstractMapProviderFactory<GlobalLockProvider,MapLockEntity,MapLockEntity>
- Returns:
true
if the provider is supported and should be available,false
otherwise
-
getHelpText
public String getHelpText()
- Specified by:
getHelpText
in interfaceConfiguredProvider
-
getConfigMetadata
public List<ProviderConfigProperty> getConfigMetadata()
Description copied from interface:ProviderFactory
Returns the metadata for each configuration property supported by this factory.- Specified by:
getConfigMetadata
in interfaceProviderFactory<GlobalLockProvider>
- Returns:
- a list with the metadata for each configuration property supported by this factory
-
-