Package org.infinispan.interceptors.impl
Class AbstractIracLocalSiteInterceptor
java.lang.Object
org.infinispan.interceptors.BaseAsyncInterceptor
org.infinispan.interceptors.DDAsyncInterceptor
org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor
- All Implemented Interfaces:
Visitor,AsyncInterceptor,LogSupplier
- Direct Known Subclasses:
NonTxIracLocalSiteInterceptor,OptimisticTxIracLocalSiteInterceptor,PessimisticTxIracLocalInterceptor
public abstract class AbstractIracLocalSiteInterceptor
extends DDAsyncInterceptor
implements LogSupplier
A
DDAsyncInterceptor with common code for all the IRAC related interceptors.- Since:
- 11.0
- Author:
- Pedro Ruivo
-
Field Summary
FieldsFields inherited from class org.infinispan.interceptors.BaseAsyncInterceptor
cacheConfiguration -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected LocalizedCacheTopologyprotected DistributionInfogetDistributionInfo(int segment) final LoggetLog()protected intgetSegment(WriteCommand command, Object key) protected static booleanisIracState(FlagAffectedCommand command) protected static booleanisNormalWriteCommand(WriteCommand command) protected booleanisPrimaryOwner(org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData data) final booleanprotected booleanisWriteOwner(org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData data) protected voidsetMetadataToCacheEntry(CacheEntry<?, ?> entry, int segment, IracMetadata metadata) protected booleanskipEntryCommit(InvocationContext ctx, WriteCommand command, Object key) protected Stream<org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData>streamKeysFromCommand(WriteCommand command) protected Stream<org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData>streamKeysFromModifications(Stream<WriteCommand> modsStream) protected ObjectvisitNonTxDataWriteCommand(InvocationContext ctx, DataWriteCommand command) protected voidvisitNonTxKey(InvocationContext ctx, Object key, WriteCommand command) Visits theWriteCommandbefore executing it.final ObjectvisitRemoveExpiredCommand(InvocationContext ctx, RemoveExpiredCommand command) Methods inherited from class org.infinispan.interceptors.DDAsyncInterceptor
handleDefault, visitClearCommand, visitCommand, visitCommitCommand, visitComputeCommand, visitComputeIfAbsentCommand, visitEntrySetCommand, visitEvictCommand, visitGetAllCommand, visitGetCacheEntryCommand, visitGetKeyValueCommand, visitInvalidateCommand, visitInvalidateL1Command, visitIracPutKeyValueCommand, visitKeySetCommand, visitLockControlCommand, visitPrepareCommand, visitPutKeyValueCommand, visitPutMapCommand, visitReadOnlyKeyCommand, visitReadOnlyManyCommand, visitReadWriteKeyCommand, visitReadWriteKeyValueCommand, visitReadWriteManyCommand, visitReadWriteManyEntriesCommand, visitRemoveCommand, visitReplaceCommand, visitRollbackCommand, visitSizeCommand, visitTouchCommand, visitUnknownCommand, visitWriteOnlyKeyCommand, visitWriteOnlyKeyValueCommand, visitWriteOnlyManyCommand, visitWriteOnlyManyEntriesCommandMethods inherited from class org.infinispan.interceptors.BaseAsyncInterceptor
asyncInvokeNext, asyncInvokeNext, asyncInvokeNext, asyncValue, delayedNull, delayedValue, delayedValue, invokeNext, invokeNextAndExceptionally, invokeNextAndFinally, invokeNextAndHandle, invokeNextThenAccept, invokeNextThenApply, isSuccessfullyDone, makeStage, setNextInterceptor, valueOrException
-
Field Details
-
log
-
-
Constructor Details
-
AbstractIracLocalSiteInterceptor
public AbstractIracLocalSiteInterceptor()
-
-
Method Details
-
visitRemoveExpiredCommand
- Specified by:
visitRemoveExpiredCommandin interfaceVisitor
-
isTraceEnabled
public final boolean isTraceEnabled()- Specified by:
isTraceEnabledin interfaceLogSupplier- Returns:
trueif "TRACE" is enabled in thisLoginstance,falseotherwise.
-
getLog
- Specified by:
getLogin interfaceLogSupplier- Returns:
- The
Loginstance.
-
isNormalWriteCommand
-
isIracState
-
getDistributionInfo
-
isWriteOwner
protected boolean isWriteOwner(org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData data) -
isPrimaryOwner
protected boolean isPrimaryOwner(org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData data) -
getCacheTopology
-
getSegment
-
setMetadataToCacheEntry
-
streamKeysFromModifications
protected Stream<org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData> streamKeysFromModifications(Stream<WriteCommand> modsStream) -
streamKeysFromCommand
protected Stream<org.infinispan.interceptors.impl.AbstractIracLocalSiteInterceptor.StreamData> streamKeysFromCommand(WriteCommand command) -
skipEntryCommit
-
visitNonTxDataWriteCommand
-
visitNonTxKey
Visits theWriteCommandbefore executing it.The primary owner generates a new
IracMetadataand stores it in theWriteCommand.
-