Class RemoteUserLoginFailureProviderFactory
java.lang.Object
org.keycloak.models.sessions.infinispan.remote.RemoteUserLoginFailureProviderFactory
- All Implemented Interfaces:
UpdaterFactory<LoginFailureKey,
,LoginFailureEntity, LoginFailuresUpdater> RemoteChangeLogTransaction.SharedState<LoginFailureKey,
,LoginFailureEntity> UserLoginFailureProviderFactory<RemoteUserLoginFailureProvider>
,EnvironmentDependentProviderFactory
,ProviderFactory<RemoteUserLoginFailureProvider>
,ServerInfoAwareProviderFactory
public class RemoteUserLoginFailureProviderFactory
extends Object
implements UserLoginFailureProviderFactory<RemoteUserLoginFailureProvider>, UpdaterFactory<LoginFailureKey,LoginFailureEntity,LoginFailuresUpdater>, EnvironmentDependentProviderFactory, RemoteChangeLogTransaction.SharedState<LoginFailureKey,LoginFailureEntity>, ServerInfoAwareProviderFactory
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
org.infinispan.util.concurrent.BlockingManager
org.infinispan.client.hotrod.RemoteCache<LoginFailureKey,
LoginFailureEntity> cache()
void
close()
This is called when the server shuts down.create
(KeycloakSession session) create
(LoginFailureKey key, LoginFailureEntity entity) Creates anUpdater
for an entity created by the current Keycloak transaction.deleted
(LoginFailureKey key) Deletes a entity that was not previous read by the Keycloak transaction.Returns the metadata for each configuration property supported by this factory.getId()
Return actual info about the provider.void
init
(Config.Scope config) Only called once when the factory is first created.boolean
isSupported
(Config.Scope config) Check if the provider is supported and should be available based on the provider configuration.int
int
order()
void
postInit
(KeycloakSessionFactory factory) Called after all provider factories have been initializedvoid
setMaxRetries
(int maxRetries) wrapFromCache
(LoginFailureKey key, LoginFailureEntity value, long version) Wraps an entity read from the Infinispan cache.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.keycloak.provider.ProviderFactory
dependsOn
Methods inherited from interface org.keycloak.models.sessions.infinispan.changes.remote.updater.UpdaterFactory
wrapFromCache
-
Field Details
-
PROTO_ENTITY
-
-
Constructor Details
-
RemoteUserLoginFailureProviderFactory
public RemoteUserLoginFailureProviderFactory()
-
-
Method Details
-
create
- Specified by:
create
in interfaceProviderFactory<RemoteUserLoginFailureProvider>
-
init
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<RemoteUserLoginFailureProvider>
-
postInit
Description copied from interface:ProviderFactory
Called after all provider factories have been initialized- Specified by:
postInit
in interfaceProviderFactory<RemoteUserLoginFailureProvider>
-
close
public void close()Description copied from interface:ProviderFactory
This is called when the server shuts down.- Specified by:
close
in interfaceProviderFactory<RemoteUserLoginFailureProvider>
-
getId
- Specified by:
getId
in interfaceProviderFactory<RemoteUserLoginFailureProvider>
-
order
public int order()- Specified by:
order
in interfaceProviderFactory<RemoteUserLoginFailureProvider>
-
isSupported
Description copied from interface:EnvironmentDependentProviderFactory
Check if the provider is supported and should be available based on the provider configuration.- Specified by:
isSupported
in interfaceEnvironmentDependentProviderFactory
- Parameters:
config
- the provider configuration- Returns:
true
if the provider is supported. Otherwise,false
.
-
getConfigMetadata
Description copied from interface:ProviderFactory
Returns the metadata for each configuration property supported by this factory.- Specified by:
getConfigMetadata
in interfaceProviderFactory<RemoteUserLoginFailureProvider>
- Returns:
- a list with the metadata for each configuration property supported by this factory
-
getOperationalInfo
Description copied from interface:ServerInfoAwareProviderFactory
Return actual info about the provider. This info contains information about provider's configuration and operational conditions (eg. errors in connection to remote systems etc) which is shown on "Server Info" page then.- Specified by:
getOperationalInfo
in interfaceServerInfoAwareProviderFactory
- Returns:
- Map with keys describing value and relevant values itself
-
create
Description copied from interface:UpdaterFactory
Creates anUpdater
for an entity created by the current Keycloak transaction.- Specified by:
create
in interfaceUpdaterFactory<LoginFailureKey,
LoginFailureEntity, LoginFailuresUpdater> - Parameters:
key
- The Infinispan key.entity
- The Infinispan value.- Returns:
- The
Updater
to be used when updating the entity state.
-
wrapFromCache
public LoginFailuresUpdater wrapFromCache(LoginFailureKey key, LoginFailureEntity value, long version) Description copied from interface:UpdaterFactory
Wraps an entity read from the Infinispan cache.- Specified by:
wrapFromCache
in interfaceUpdaterFactory<LoginFailureKey,
LoginFailureEntity, LoginFailuresUpdater> - Parameters:
key
- The Infinispan key.value
- The Infinispan value.version
- The entry version.- Returns:
- The
Updater
to be used when updating the entity state.
-
deleted
Description copied from interface:UpdaterFactory
Deletes a entity that was not previous read by the Keycloak transaction.- Specified by:
deleted
in interfaceUpdaterFactory<LoginFailureKey,
LoginFailureEntity, LoginFailuresUpdater> - Parameters:
key
- The Infinispan key.- Returns:
- The
Updater
for a deleted entity.
-
cache
- Specified by:
cache
in interfaceRemoteChangeLogTransaction.SharedState<LoginFailureKey,
LoginFailureEntity>
-
maxRetries
public int maxRetries()- Specified by:
maxRetries
in interfaceRemoteChangeLogTransaction.SharedState<LoginFailureKey,
LoginFailureEntity>
-
backOffBaseTimeMillis
public int backOffBaseTimeMillis()- Specified by:
backOffBaseTimeMillis
in interfaceRemoteChangeLogTransaction.SharedState<LoginFailureKey,
LoginFailureEntity>
-
blockingManager
public org.infinispan.util.concurrent.BlockingManager blockingManager()- Specified by:
blockingManager
in interfaceRemoteChangeLogTransaction.SharedState<LoginFailureKey,
LoginFailureEntity>
-
setMaxRetries
public void setMaxRetries(int maxRetries)
-