Package org.infinispan.distribution.impl
Class L1ManagerImpl
- java.lang.Object
-
- org.infinispan.distribution.impl.L1ManagerImpl
-
- All Implemented Interfaces:
L1Manager,RemoteValueRetrievedListener
public class L1ManagerImpl extends Object implements L1Manager, RemoteValueRetrievedListener
-
-
Constructor Summary
Constructors Constructor Description L1ManagerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddRequestor(Object key, Address origin)Records a request that will be cached in another nodes L1CompletableFuture<?>flushCache(Collection<Object> keys, Address origin, boolean assumeOriginKeptEntryInL1)voidregisterL1WriteSynchronizer(Object key, L1WriteSynchronizer sync)Registers the given write synchronizer to be notified whenever a remote value is looked up for the given key.voidremoteValueFound(InternalCacheEntry ice)Invoked when a remote value is found from a remote sourcevoidremoteValueNotFound(Object key)Invoked when a remote value is not found from the remote source for the given keyvoidstart()voidstop()voidunregisterL1WriteSynchronizer(Object key, L1WriteSynchronizer sync)Unregister the given write synchronizer if present.
-
-
-
Method Detail
-
start
public void start()
-
stop
public void stop()
-
addRequestor
public void addRequestor(Object key, Address origin)
Description copied from interface:L1ManagerRecords a request that will be cached in another nodes L1- Specified by:
addRequestorin interfaceL1Manager
-
flushCache
public CompletableFuture<?> flushCache(Collection<Object> keys, Address origin, boolean assumeOriginKeptEntryInL1)
- Specified by:
flushCachein interfaceL1Manager
-
registerL1WriteSynchronizer
public void registerL1WriteSynchronizer(Object key, L1WriteSynchronizer sync)
Description copied from interface:L1ManagerRegisters 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:
registerL1WriteSynchronizerin 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, L1WriteSynchronizer sync)
Description copied from interface:L1ManagerUnregister 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:
unregisterL1WriteSynchronizerin interfaceL1Manager- Parameters:
key- The key to unregister the given synchronizer for.sync- The synchronizer to be removed if it is still present.
-
remoteValueFound
public void remoteValueFound(InternalCacheEntry ice)
Description copied from interface:RemoteValueRetrievedListenerInvoked when a remote value is found from a remote source- Specified by:
remoteValueFoundin interfaceRemoteValueRetrievedListener- Parameters:
ice- The cache entry that was found
-
remoteValueNotFound
public void remoteValueNotFound(Object key)
Description copied from interface:RemoteValueRetrievedListenerInvoked when a remote value is not found from the remote source for the given key- Specified by:
remoteValueNotFoundin interfaceRemoteValueRetrievedListener- Parameters:
key- The key for which there was no value found
-
-