Class CounterInterceptor
java.lang.Object
org.infinispan.interceptors.BaseAsyncInterceptor
org.infinispan.interceptors.DDAsyncInterceptor
org.infinispan.interceptors.BaseCustomAsyncInterceptor
org.infinispan.counter.impl.interceptor.CounterInterceptor
- All Implemented Interfaces:
org.infinispan.commands.Visitor,org.infinispan.interceptors.AsyncInterceptor
public class CounterInterceptor
extends org.infinispan.interceptors.BaseCustomAsyncInterceptor
Interceptor for the counters cache.
Since the state transfer doesn't know about the Flag.SKIP_CACHE_STORE and Flag.SKIP_CACHE_LOAD flags,
all the counters are persisted. However, we only want the Storage.PERSISTENT configurations to be persisted.
This interceptor checks the configuration's Storage and sets the Flag.SKIP_CACHE_LOAD and Flag.SKIP_CACHE_STORE flags.
- Since:
- 9.0
- Author:
- Pedro Ruivo
-
Field Summary
Fields inherited from class org.infinispan.interceptors.BaseCustomAsyncInterceptor
cache, embeddedCacheManagerFields inherited from class org.infinispan.interceptors.BaseAsyncInterceptor
cacheConfiguration -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvisitPutKeyValueCommand(org.infinispan.context.InvocationContext ctx, org.infinispan.commands.write.PutKeyValueCommand command) Methods inherited from class org.infinispan.interceptors.BaseCustomAsyncInterceptor
start, stopMethods inherited from class org.infinispan.interceptors.DDAsyncInterceptor
handleDefault, visitClearCommand, visitCommand, visitCommitCommand, visitComputeCommand, visitComputeIfAbsentCommand, visitEntrySetCommand, visitEvictCommand, visitGetAllCommand, visitGetCacheEntryCommand, visitGetKeyValueCommand, visitInvalidateCommand, visitInvalidateL1Command, visitIracPutKeyValueCommand, visitKeySetCommand, visitLockControlCommand, visitPrepareCommand, 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, valueOrExceptionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.infinispan.commands.Visitor
visitRemoveExpiredCommand
-
Constructor Details
-
CounterInterceptor
public CounterInterceptor()
-
-
Method Details
-
visitPutKeyValueCommand
public Object visitPutKeyValueCommand(org.infinispan.context.InvocationContext ctx, org.infinispan.commands.write.PutKeyValueCommand command) throws Throwable - Specified by:
visitPutKeyValueCommandin interfaceorg.infinispan.commands.Visitor- Overrides:
visitPutKeyValueCommandin classorg.infinispan.interceptors.DDAsyncInterceptor- Throws:
Throwable
-