Class WATCH
java.lang.Object
org.infinispan.server.resp.RespCommand
org.infinispan.server.resp.commands.tx.WATCH
- All Implemented Interfaces:
BaseResp3Command,Resp3Command,TransactionResp3Command
WATCH
Installs a clustered listener to watch for the given keys. The listener receives events for creation,
updates, and expiration.
The watch instance is local to a single ChannelHandlerContext. To remove the listeners, the same context
needs to execute the operation. There is no way to remove a single specific watcher. All listeners deregister during
an EXEC, UNWATCH, DISCARD, transaction abort, or closed channel.
Since a listener is bound to a single connection, this ensures that another client does not affect each other's transactions safeguards.
- Since:
- 15.0
- Author:
- José Bolina
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic class -
Field Summary
Fields inherited from class org.infinispan.server.resp.RespCommand
log -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionperform(Resp3Handler handler, io.netty.channel.ChannelHandlerContext ctx, List<byte[]> arguments) perform(RespTransactionHandler handler, io.netty.channel.ChannelHandlerContext ctx, List<byte[]> arguments) voidregister(io.netty.channel.ChannelHandlerContext ctx, WATCH.TxKeysListener listener) Methods inherited from class org.infinispan.server.resp.RespCommand
aclMask, extractKeys, fromByteBuf, fromString, getArity, getFirstKeyPos, getLastKeyPos, getName, getSteps, handleException, hasValidNumberOfArguments, match, size, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.infinispan.server.resp.commands.BaseResp3Command
aclMask
-
Constructor Details
-
WATCH
public WATCH()
-
-
Method Details
-
perform
public CompletionStage<RespRequestHandler> perform(Resp3Handler handler, io.netty.channel.ChannelHandlerContext ctx, List<byte[]> arguments) - Specified by:
performin interfaceResp3Command
-
perform
public CompletionStage<RespRequestHandler> perform(RespTransactionHandler handler, io.netty.channel.ChannelHandlerContext ctx, List<byte[]> arguments) - Specified by:
performin interfaceTransactionResp3Command
-
register
-