Package org.keycloak.cluster.infinispan
Class InfinispanClusterProvider
java.lang.Object
org.keycloak.cluster.infinispan.InfinispanClusterProvider
- All Implemented Interfaces:
ClusterProvider,Provider
- Author:
- Marek Posolda
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.keycloak.cluster.ClusterProvider
ClusterProvider.DCNotify -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionInfinispanClusterProvider(int clusterStartupTime, String myAddress, org.keycloak.cluster.infinispan.CrossDCAwareCacheFactory crossDCAwareCacheFactory, InfinispanNotificationsManager notificationsManager, ExecutorService localExecutor) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()<T> ExecutionResult<T>executeIfNotExecuted(String taskKey, int taskTimeoutInSeconds, Callable<T> task) executeIfNotExecutedAsync(String taskKey, int taskTimeoutInSeconds, Callable task) intvoidnotify(String taskKey, ClusterEvent event, boolean ignoreSender, ClusterProvider.DCNotify dcNotify) voidregisterListener(String taskKey, ClusterListener task)
-
Field Details
-
logger
protected static final org.jboss.logging.Logger logger -
CLUSTER_STARTUP_TIME_KEY
- See Also:
-
TASK_KEY_PREFIX
- See Also:
-
-
Constructor Details
-
InfinispanClusterProvider
public InfinispanClusterProvider(int clusterStartupTime, String myAddress, org.keycloak.cluster.infinispan.CrossDCAwareCacheFactory crossDCAwareCacheFactory, InfinispanNotificationsManager notificationsManager, ExecutorService localExecutor)
-
-
Method Details
-
getClusterStartupTime
public int getClusterStartupTime()- Specified by:
getClusterStartupTimein interfaceClusterProvider
-
close
public void close() -
executeIfNotExecuted
public <T> ExecutionResult<T> executeIfNotExecuted(String taskKey, int taskTimeoutInSeconds, Callable<T> task) - Specified by:
executeIfNotExecutedin interfaceClusterProvider
-
executeIfNotExecutedAsync
public Future<Boolean> executeIfNotExecutedAsync(String taskKey, int taskTimeoutInSeconds, Callable task) - Specified by:
executeIfNotExecutedAsyncin interfaceClusterProvider
-
registerListener
- Specified by:
registerListenerin interfaceClusterProvider
-
notify
public void notify(String taskKey, ClusterEvent event, boolean ignoreSender, ClusterProvider.DCNotify dcNotify) - Specified by:
notifyin interfaceClusterProvider
-