Package org.infinispan.distribution.impl
Class L1ManagerImpl
java.lang.Object
org.infinispan.distribution.impl.L1ManagerImpl
- All Implemented Interfaces:
L1Manager
,RemoteValueRetrievedListener
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addRequestor
(Object key, Address origin) Records a request that will be cached in another nodes L1flushCache
(Collection<Object> keys, Address origin, boolean assumeOriginKeptEntryInL1) void
registerL1WriteSynchronizer
(Object key, org.infinispan.interceptors.distribution.L1WriteSynchronizer sync) Registers the given write synchronizer to be notified whenever a remote value is looked up for the given key.void
Invoked when a remote value is found from a remote sourcevoid
Invoked when a remote value is not found from the remote source for the given keyvoid
start()
void
stop()
void
unregisterL1WriteSynchronizer
(Object key, org.infinispan.interceptors.distribution.L1WriteSynchronizer sync) Unregister the given write synchronizer if present.
-
Constructor Details
-
L1ManagerImpl
public L1ManagerImpl()
-
-
Method Details
-
start
public void start() -
stop
public void stop() -
addRequestor
Description copied from interface:L1Manager
Records a request that will be cached in another nodes L1- Specified by:
addRequestor
in interfaceL1Manager
-
flushCache
public CompletableFuture<?> flushCache(Collection<Object> keys, Address origin, boolean assumeOriginKeptEntryInL1) - Specified by:
flushCache
in interfaceL1Manager
-
registerL1WriteSynchronizer
public void registerL1WriteSynchronizer(Object key, org.infinispan.interceptors.distribution.L1WriteSynchronizer sync) Description copied from interface:L1Manager
Registers the given write synchronizer to be notified whenever a remote value is looked up for the given key. If the synchronizer is no longer needed to be signaled, the user should unregister it usingL1Manager.unregisterL1WriteSynchronizer(Object, org.infinispan.interceptors.distribution.L1WriteSynchronizer)
- Specified by:
registerL1WriteSynchronizer
in interfaceL1Manager
- Parameters:
key
- The key that that when looked up will trigger the synchronizersync
- The synchronizer to run the update when the key is looked up
-
unregisterL1WriteSynchronizer
public void unregisterL1WriteSynchronizer(Object key, org.infinispan.interceptors.distribution.L1WriteSynchronizer sync) Description copied from interface:L1Manager
Unregister the given write synchronizer if present. Note the synchronizer is only unregistered if it matches using instance equality (==) due to possibly concurrent usage of write synchronizers- Specified by:
unregisterL1WriteSynchronizer
in interfaceL1Manager
- Parameters:
key
- The key to unregister the given synchronizer for.sync
- The synchronizer to be removed if it is still present.
-
remoteValueFound
Description copied from interface:RemoteValueRetrievedListener
Invoked when a remote value is found from a remote source- Specified by:
remoteValueFound
in interfaceRemoteValueRetrievedListener
- Parameters:
ice
- The cache entry that was found
-
remoteValueNotFound
Description copied from interface:RemoteValueRetrievedListener
Invoked when a remote value is not found from the remote source for the given key- Specified by:
remoteValueNotFound
in interfaceRemoteValueRetrievedListener
- Parameters:
key
- The key for which there was no value found
-