Package io.lettuce.core.cluster.api.sync
Interface RedisAdvancedClusterCommands<K,V>
-
- All Superinterfaces:
BaseRedisCommands<K,V>
,RedisAclCommands<K,V>
,RedisClusterCommands<K,V>
,RedisFunctionCommands<K,V>
,RedisGeoCommands<K,V>
,RedisHashCommands<K,V>
,RedisHLLCommands<K,V>
,RedisKeyCommands<K,V>
,RedisListCommands<K,V>
,RedisScriptingCommands<K,V>
,RedisServerCommands<K,V>
,RedisSetCommands<K,V>
,RedisSortedSetCommands<K,V>
,RedisStreamCommands<K,V>
,RedisStringCommands<K,V>
public interface RedisAdvancedClusterCommands<K,V> extends RedisClusterCommands<K,V>
Advanced synchronous and thread-safe Redis Cluster API.- Since:
- 4.0
- Author:
- Mark Paluch, Jon Chambers
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description default NodeSelection<K,V>
all()
Select all known cluster nodes.String
clientSetname(K name)
Set the current connection name on all known cluster nodes with pipelining.Long
dbsize()
Return the number of keys in the selected database on all cluster upstream nodes.Long
del(K... keys)
Delete one or more keys with pipelining.Long
exists(K... keys)
Determine how many keys exist with pipelining.String
flushall()
Remove all keys from all databases on all cluster upstream nodes with pipelining.String
flushallAsync()
Remove all keys asynchronously from all databases on all cluster upstream nodes with pipelining.String
flushdb()
Remove all keys from the current database on all cluster upstream nodes with pipelining.RedisClusterCommands<K,V>
getConnection(String nodeId)
Retrieve a connection to the specified cluster node using the nodeId.RedisClusterCommands<K,V>
getConnection(String host, int port)
Retrieve a connection to the specified cluster node using host and port.StatefulRedisClusterConnection<K,V>
getStatefulConnection()
Deprecated.Long
keys(KeyStreamingChannel<K> channel, K pattern)
Find all keys matching the given pattern on all cluster upstream nodes.List<K>
keys(K pattern)
Find all keys matching the given pattern on all cluster upstream nodes.default NodeSelection<K,V>
masters()
Deprecated.since 6.0 in favor ofupstream()
.List<KeyValue<K,V>>
mget(K... keys)
Get the values of all the given keys with pipelining.String
mset(Map<K,V> map)
Set multiple keys to multiple values with pipelining.Boolean
msetnx(Map<K,V> map)
Set multiple keys to multiple values, only if none of the keys exist with pipelining.NodeSelection<K,V>
nodes(Predicate<RedisClusterNode> predicate)
Select nodes by a predicate and keeps a static selection.NodeSelection<K,V>
nodes(Predicate<RedisClusterNode> predicate, boolean dynamic)
Select nodes by a predicateK
randomkey()
Return a random key from the keyspace on a random master.NodeSelection<K,V>
readonly(Predicate<RedisClusterNode> predicate)
Select replica nodes by a predicate and keeps a static selection.default NodeSelection<K,V>
replicas()
Select all replicas.default NodeSelection<K,V>
replicas(Predicate<RedisClusterNode> predicate)
Select all replicas.KeyScanCursor<K>
scan()
Incrementally iterate the keys space over the whole Cluster.StreamScanCursor
scan(KeyStreamingChannel<K> channel)
Incrementally iterate the keys space over the whole Cluster.StreamScanCursor
scan(KeyStreamingChannel<K> channel, ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.StreamScanCursor
scan(KeyStreamingChannel<K> channel, ScanCursor scanCursor)
Incrementally iterate the keys space over the whole Cluster.StreamScanCursor
scan(KeyStreamingChannel<K> channel, ScanCursor scanCursor, ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.KeyScanCursor<K>
scan(ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.KeyScanCursor<K>
scan(ScanCursor scanCursor)
Incrementally iterate the keys space over the whole Cluster.KeyScanCursor<K>
scan(ScanCursor scanCursor, ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.String
scriptFlush()
Remove all the scripts from the script cache on all cluster nodes.String
scriptKill()
Kill the script currently in execution on all cluster nodes.void
shutdown(boolean save)
Synchronously save the dataset to disk and then shut down all nodes of the cluster.default NodeSelection<K,V>
slaves()
Deprecated.since 5.2, usereplicas()
default NodeSelection<K,V>
slaves(Predicate<RedisClusterNode> predicate)
Deprecated.since 5.2, usereplicas(Predicate)
Long
touch(K... keys)
Touch one or more keys with pipelining.Long
unlink(K... keys)
Unlink one or more keys with pipelining.default NodeSelection<K,V>
upstream()
Select all upstream nodes.-
Methods inherited from interface io.lettuce.core.api.sync.BaseRedisCommands
dispatch, dispatch, echo, isOpen, ping, publish, pubsubChannels, pubsubChannels, pubsubNumpat, pubsubNumsub, quit, reset, role, waitForReplication
-
Methods inherited from interface io.lettuce.core.api.sync.RedisAclCommands
aclCat, aclCat, aclDeluser, aclDryRun, aclDryRun, aclGenpass, aclGenpass, aclGetuser, aclList, aclLoad, aclLog, aclLog, aclLogReset, aclSave, aclSetuser, aclUsers, aclWhoami
-
Methods inherited from interface io.lettuce.core.cluster.api.sync.RedisClusterCommands
asking, auth, auth, clusterAddSlots, clusterAddSlotsRange, clusterBumpepoch, clusterCountFailureReports, clusterCountKeysInSlot, clusterDelSlots, clusterDelSlotsRange, clusterFailover, clusterFailover, clusterFlushslots, clusterForget, clusterGetKeysInSlot, clusterInfo, clusterKeyslot, clusterMeet, clusterMyId, clusterNodes, clusterReplicas, clusterReplicate, clusterReset, clusterSaveconfig, clusterSetConfigEpoch, clusterSetSlotImporting, clusterSetSlotMigrating, clusterSetSlotNode, clusterSetSlotStable, clusterShards, clusterSlaves, clusterSlots, readOnly, readWrite, setTimeout
-
Methods inherited from interface io.lettuce.core.api.sync.RedisFunctionCommands
fcall, fcall, fcallReadOnly, fcallReadOnly, functionDump, functionFlush, functionKill, functionList, functionList, functionLoad, functionLoad, functionRestore, functionRestore
-
Methods inherited from interface io.lettuce.core.api.sync.RedisGeoCommands
geoadd, geoadd, geoadd, geoadd, geoadd, geoadd, geodist, geohash, geopos, georadius, georadius, georadius, georadiusbymember, georadiusbymember, georadiusbymember, geosearch, geosearch, geosearchstore
-
Methods inherited from interface io.lettuce.core.api.sync.RedisHashCommands
hdel, hexists, hget, hgetall, hgetall, hincrby, hincrbyfloat, hkeys, hkeys, hlen, hmget, hmget, hmset, hrandfield, hrandfield, hrandfieldWithvalues, hrandfieldWithvalues, hscan, hscan, hscan, hscan, hscan, hscan, hscan, hscan, hset, hset, hsetnx, hstrlen, hvals, hvals
-
Methods inherited from interface io.lettuce.core.api.sync.RedisHLLCommands
pfadd, pfcount, pfmerge
-
Methods inherited from interface io.lettuce.core.api.sync.RedisKeyCommands
copy, copy, dump, expire, expire, expire, expire, expireat, expireat, expireat, expireat, expireat, expireat, expiretime, migrate, migrate, move, objectEncoding, objectFreq, objectIdletime, objectRefcount, persist, pexpire, pexpire, pexpire, pexpire, pexpireat, pexpireat, pexpireat, pexpireat, pexpireat, pexpireat, pexpiretime, pttl, rename, renamenx, restore, restore, sort, sort, sort, sort, sortReadOnly, sortReadOnly, sortReadOnly, sortReadOnly, sortStore, ttl, type
-
Methods inherited from interface io.lettuce.core.api.sync.RedisListCommands
blmove, blmove, blmpop, blmpop, blpop, blpop, brpop, brpop, brpoplpush, brpoplpush, lindex, linsert, llen, lmove, lmpop, lpop, lpop, lpos, lpos, lpos, lpos, lpush, lpushx, lrange, lrange, lrem, lset, ltrim, rpop, rpop, rpoplpush, rpush, rpushx
-
Methods inherited from interface io.lettuce.core.api.sync.RedisScriptingCommands
digest, digest, eval, eval, eval, eval, evalReadOnly, evalsha, evalsha, evalshaReadOnly, scriptExists, scriptFlush, scriptLoad, scriptLoad
-
Methods inherited from interface io.lettuce.core.api.sync.RedisServerCommands
bgrewriteaof, bgsave, clientCaching, clientGetname, clientGetredir, clientId, clientInfo, clientKill, clientKill, clientList, clientList, clientNoEvict, clientPause, clientSetinfo, clientTracking, clientUnblock, command, commandCount, commandInfo, commandInfo, configGet, configGet, configResetstat, configRewrite, configSet, configSet, debugCrashAndRecover, debugHtstats, debugObject, debugOom, debugReload, debugRestart, debugSdslen, debugSegfault, flushall, flushdb, flushdbAsync, info, info, lastsave, memoryUsage, replicaof, replicaofNoOne, save, shutdown, slaveof, slaveofNoOne, slowlogGet, slowlogGet, slowlogLen, slowlogReset, time
-
Methods inherited from interface io.lettuce.core.api.sync.RedisSetCommands
sadd, scard, sdiff, sdiff, sdiffstore, sinter, sinter, sintercard, sintercard, sinterstore, sismember, smembers, smembers, smismember, smove, spop, spop, srandmember, srandmember, srandmember, srem, sscan, sscan, sscan, sscan, sscan, sscan, sscan, sscan, sunion, sunion, sunionstore
-
Methods inherited from interface io.lettuce.core.api.sync.RedisSortedSetCommands
bzmpop, bzmpop, bzmpop, bzmpop, bzpopmax, bzpopmax, bzpopmin, bzpopmin, zadd, zadd, zadd, zadd, zadd, zadd, zaddincr, zaddincr, zcard, zcount, zcount, zcount, zdiff, zdiffstore, zdiffWithScores, zincrby, zinter, zinter, zintercard, zintercard, zinterstore, zinterstore, zinterWithScores, zinterWithScores, zlexcount, zlexcount, zmpop, zmpop, zmscore, zpopmax, zpopmax, zpopmin, zpopmin, zrandmember, zrandmember, zrandmemberWithScores, zrandmemberWithScores, zrange, zrange, zrangebylex, zrangebylex, zrangebylex, zrangebylex, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscore, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangebyscoreWithScores, zrangestore, zrangestorebylex, zrangestorebyscore, zrangeWithScores, zrangeWithScores, zrank, zrankWithScore, zrem, zremrangebylex, zremrangebylex, zremrangebyrank, zremrangebyscore, zremrangebyscore, zremrangebyscore, zrevrange, zrevrange, zrevrangebylex, zrevrangebylex, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscore, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangebyscoreWithScores, zrevrangestore, zrevrangestorebylex, zrevrangestorebyscore, zrevrangeWithScores, zrevrangeWithScores, zrevrank, zrevrankWithScore, zscan, zscan, zscan, zscan, zscan, zscan, zscan, zscan, zscore, zunion, zunion, zunionstore, zunionstore, zunionWithScores, zunionWithScores
-
Methods inherited from interface io.lettuce.core.api.sync.RedisStreamCommands
xack, xadd, xadd, xadd, xadd, xautoclaim, xclaim, xclaim, xdel, xgroupCreate, xgroupCreate, xgroupCreateconsumer, xgroupDelconsumer, xgroupDestroy, xgroupSetid, xinfoConsumers, xinfoGroups, xinfoStream, xlen, xpending, xpending, xpending, xpending, xrange, xrange, xread, xread, xreadgroup, xreadgroup, xrevrange, xrevrange, xtrim, xtrim, xtrim
-
Methods inherited from interface io.lettuce.core.api.sync.RedisStringCommands
append, bitcount, bitcount, bitfield, bitopAnd, bitopNot, bitopOr, bitopXor, bitpos, bitpos, bitpos, decr, decrby, get, getbit, getdel, getex, getrange, getset, incr, incrby, incrbyfloat, mget, psetex, set, set, setbit, setex, setGet, setGet, setnx, setrange, stralgoLcs, strlen
-
-
-
-
Method Detail
-
getConnection
RedisClusterCommands<K,V> getConnection(String nodeId)
Retrieve a connection to the specified cluster node using the nodeId. Host and port are looked up in the node list. In contrast to theRedisAdvancedClusterCommands
, node-connections do not route commands to other cluster nodes- Parameters:
nodeId
- the node Id- Returns:
- a connection to the requested cluster node
-
getConnection
RedisClusterCommands<K,V> getConnection(String host, int port)
Retrieve a connection to the specified cluster node using host and port. In contrast to theRedisAdvancedClusterCommands
, node-connections do not route commands to other cluster nodes. Host and port connections are verified by default for cluster membership, seeClusterClientOptions.isValidateClusterNodeMembership()
.- Parameters:
host
- the hostport
- the port- Returns:
- a connection to the requested cluster node
-
getStatefulConnection
@Deprecated StatefulRedisClusterConnection<K,V> getStatefulConnection()
Deprecated.- Returns:
- the underlying connection.
- Since:
- 6.2, will be removed with Lettuce 7 to avoid exposing the underlying connection.
-
masters
@Deprecated default NodeSelection<K,V> masters()
Deprecated.since 6.0 in favor ofupstream()
.Select all upstream nodes.- Returns:
- API with synchronous executed commands on a selection of upstream cluster nodes.
-
upstream
default NodeSelection<K,V> upstream()
Select all upstream nodes.- Returns:
- API with synchronous executed commands on a selection of upstream cluster nodes.
-
slaves
@Deprecated default NodeSelection<K,V> slaves()
Deprecated.since 5.2, usereplicas()
Select all replicas.- Returns:
- API with synchronous executed commands on a selection of replica cluster nodes.
-
slaves
@Deprecated default NodeSelection<K,V> slaves(Predicate<RedisClusterNode> predicate)
Deprecated.since 5.2, usereplicas(Predicate)
Select all replicas.- Parameters:
predicate
- Predicate to filter nodes- Returns:
- API with synchronous executed commands on a selection of replica cluster nodes.
-
replicas
default NodeSelection<K,V> replicas()
Select all replicas.- Returns:
- API with synchronous executed commands on a selection of replica cluster nodes.
- Since:
- 5.2
-
replicas
default NodeSelection<K,V> replicas(Predicate<RedisClusterNode> predicate)
Select all replicas.- Parameters:
predicate
- Predicate to filter nodes- Returns:
- API with synchronous executed commands on a selection of replica cluster nodes.
- Since:
- 5.2
-
all
default NodeSelection<K,V> all()
Select all known cluster nodes.- Returns:
- API with synchronous executed commands on a selection of all cluster nodes.
-
readonly
NodeSelection<K,V> readonly(Predicate<RedisClusterNode> predicate)
Select replica nodes by a predicate and keeps a static selection. Replica connections operate in READONLY mode. The set of nodes within theNodeSelectionSupport
does not change when the cluster view changes.- Parameters:
predicate
- Predicate to filter nodes- Returns:
- API with synchronous executed commands on a selection of cluster nodes matching
predicate
-
nodes
NodeSelection<K,V> nodes(Predicate<RedisClusterNode> predicate)
Select nodes by a predicate and keeps a static selection. The set of nodes within theNodeSelectionSupport
does not change when the cluster view changes.- Parameters:
predicate
- Predicate to filter nodes- Returns:
- API with synchronous executed commands on a selection of cluster nodes matching
predicate
-
nodes
NodeSelection<K,V> nodes(Predicate<RedisClusterNode> predicate, boolean dynamic)
Select nodes by a predicate- Parameters:
predicate
- Predicate to filter nodesdynamic
- Defines, whether the set of nodes within theNodeSelectionSupport
can change when the cluster view changes.- Returns:
- API with synchronous executed commands on a selection of cluster nodes matching
predicate
-
del
Long del(K... keys)
Delete one or more keys with pipelining. Cross-slot keys will result in multiple calls to the particular cluster nodes.- Specified by:
del
in interfaceRedisKeyCommands<K,V>
- Parameters:
keys
- the keys- Returns:
- Long integer-reply The number of keys that were removed.
- See Also:
RedisKeyCommands.del(Object[])
-
unlink
Long unlink(K... keys)
Unlink one or more keys with pipelining. Cross-slot keys will result in multiple calls to the particular cluster nodes.- Specified by:
unlink
in interfaceRedisKeyCommands<K,V>
- Parameters:
keys
- the keys- Returns:
- Long integer-reply The number of keys that were removed.
- See Also:
RedisKeyCommands.unlink(Object[])
-
exists
Long exists(K... keys)
Determine how many keys exist with pipelining. Cross-slot keys will result in multiple calls to the particular cluster nodes.- Specified by:
exists
in interfaceRedisKeyCommands<K,V>
- Parameters:
keys
- the keys- Returns:
- Long integer-reply specifically: Number of existing keys
-
mget
List<KeyValue<K,V>> mget(K... keys)
Get the values of all the given keys with pipelining. Cross-slot keys will result in multiple calls to the particular cluster nodes.- Specified by:
mget
in interfaceRedisStringCommands<K,V>
- Parameters:
keys
- the key- Returns:
- List<V> array-reply list of values at the specified keys.
- See Also:
RedisStringCommands.mget(Object[])
-
mset
String mset(Map<K,V> map)
Set multiple keys to multiple values with pipelining. Cross-slot keys will result in multiple calls to the particular cluster nodes.- Specified by:
mset
in interfaceRedisStringCommands<K,V>
- Parameters:
map
- the map- Returns:
- String simple-string-reply always
OK
sinceMSET
can't fail. - See Also:
RedisStringCommands.mset(Map)
-
msetnx
Boolean msetnx(Map<K,V> map)
Set multiple keys to multiple values, only if none of the keys exist with pipelining. Cross-slot keys will result in multiple calls to the particular cluster nodes.- Specified by:
msetnx
in interfaceRedisStringCommands<K,V>
- Parameters:
map
- the map- Returns:
- Boolean integer-reply specifically:
1
if the all the keys were set.0
if no key was set (at least one key already existed). - See Also:
RedisStringCommands.msetnx(Map)
-
clientSetname
String clientSetname(K name)
Set the current connection name on all known cluster nodes with pipelining.- Specified by:
clientSetname
in interfaceRedisServerCommands<K,V>
- Parameters:
name
- the client name- Returns:
- simple-string-reply
OK
if the connection name was successfully set. - See Also:
RedisServerCommands.clientSetname(Object)
-
flushall
String flushall()
Remove all keys from all databases on all cluster upstream nodes with pipelining.- Specified by:
flushall
in interfaceRedisServerCommands<K,V>
- Returns:
- String simple-string-reply
- See Also:
RedisServerCommands.flushall()
-
flushallAsync
String flushallAsync()
Remove all keys asynchronously from all databases on all cluster upstream nodes with pipelining.- Specified by:
flushallAsync
in interfaceRedisServerCommands<K,V>
- Returns:
- String simple-string-reply
- Since:
- 6.0
- See Also:
RedisServerCommands.flushallAsync()
-
flushdb
String flushdb()
Remove all keys from the current database on all cluster upstream nodes with pipelining.- Specified by:
flushdb
in interfaceRedisServerCommands<K,V>
- Returns:
- String simple-string-reply
- See Also:
RedisServerCommands.flushdb()
-
dbsize
Long dbsize()
Return the number of keys in the selected database on all cluster upstream nodes.- Specified by:
dbsize
in interfaceRedisServerCommands<K,V>
- Returns:
- Long integer-reply
- See Also:
RedisServerCommands.dbsize()
-
keys
List<K> keys(K pattern)
Find all keys matching the given pattern on all cluster upstream nodes.- Specified by:
keys
in interfaceRedisKeyCommands<K,V>
- Parameters:
pattern
- the pattern type: patternkey (pattern)- Returns:
- List<K> array-reply list of keys matching
pattern
. - See Also:
RedisKeyCommands.keys(Object)
-
keys
Long keys(KeyStreamingChannel<K> channel, K pattern)
Find all keys matching the given pattern on all cluster upstream nodes.- Specified by:
keys
in interfaceRedisKeyCommands<K,V>
- Parameters:
channel
- the channelpattern
- the pattern- Returns:
- Long array-reply list of keys matching
pattern
. - See Also:
RedisKeyCommands.keys(KeyStreamingChannel, Object)
-
randomkey
K randomkey()
Return a random key from the keyspace on a random master.- Specified by:
randomkey
in interfaceRedisKeyCommands<K,V>
- Returns:
- K bulk-string-reply the random key, or
null
when the database is empty. - See Also:
RedisKeyCommands.randomkey()
-
scriptFlush
String scriptFlush()
Remove all the scripts from the script cache on all cluster nodes.- Specified by:
scriptFlush
in interfaceRedisScriptingCommands<K,V>
- Returns:
- String simple-string-reply
- See Also:
RedisScriptingCommands.scriptFlush()
-
scriptKill
String scriptKill()
Kill the script currently in execution on all cluster nodes. This call does not fail even if no scripts are running.- Specified by:
scriptKill
in interfaceRedisScriptingCommands<K,V>
- Returns:
- String simple-string-reply, always OK.
- See Also:
RedisScriptingCommands.scriptKill()
-
shutdown
void shutdown(boolean save)
Synchronously save the dataset to disk and then shut down all nodes of the cluster.- Specified by:
shutdown
in interfaceRedisServerCommands<K,V>
- Parameters:
save
-true
force save operation- See Also:
RedisServerCommands.shutdown(boolean)
-
scan
KeyScanCursor<K> scan()
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Returns:
- KeyScanCursor<K> scan cursor.
- See Also:
RedisKeyCommands.scan()
-
scan
KeyScanCursor<K> scan(ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Parameters:
scanArgs
- scan arguments- Returns:
- KeyScanCursor<K> scan cursor.
- See Also:
RedisKeyCommands.scan(ScanArgs)
-
scan
KeyScanCursor<K> scan(ScanCursor scanCursor, ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Parameters:
scanCursor
- cursor to resume the scan. It's required to reuse thescanCursor
instance from the previousscan()
call.scanArgs
- scan arguments- Returns:
- KeyScanCursor<K> scan cursor.
- See Also:
RedisKeyCommands.scan(ScanCursor, ScanArgs)
-
scan
KeyScanCursor<K> scan(ScanCursor scanCursor)
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Parameters:
scanCursor
- cursor to resume the scan. It's required to reuse thescanCursor
instance from the previousscan()
call.- Returns:
- KeyScanCursor<K> scan cursor.
- See Also:
RedisKeyCommands.scan(ScanCursor)
-
scan
StreamScanCursor scan(KeyStreamingChannel<K> channel)
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Parameters:
channel
- streaming channel that receives a call for every key- Returns:
- StreamScanCursor scan cursor.
- See Also:
RedisKeyCommands.scan(KeyStreamingChannel)
-
scan
StreamScanCursor scan(KeyStreamingChannel<K> channel, ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Parameters:
channel
- streaming channel that receives a call for every keyscanArgs
- scan arguments- Returns:
- StreamScanCursor scan cursor.
- See Also:
RedisKeyCommands.scan(KeyStreamingChannel, ScanArgs)
-
scan
StreamScanCursor scan(KeyStreamingChannel<K> channel, ScanCursor scanCursor, ScanArgs scanArgs)
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Parameters:
channel
- streaming channel that receives a call for every keyscanCursor
- cursor to resume the scan. It's required to reuse thescanCursor
instance from the previousscan()
call.scanArgs
- scan arguments- Returns:
- StreamScanCursor scan cursor.
- See Also:
RedisKeyCommands.scan(KeyStreamingChannel, ScanCursor, ScanArgs)
-
scan
StreamScanCursor scan(KeyStreamingChannel<K> channel, ScanCursor scanCursor)
Incrementally iterate the keys space over the whole Cluster.- Specified by:
scan
in interfaceRedisKeyCommands<K,V>
- Parameters:
channel
- streaming channel that receives a call for every keyscanCursor
- cursor to resume the scan. It's required to reuse thescanCursor
instance from the previousscan()
call.- Returns:
- StreamScanCursor scan cursor.
- See Also:
RedisKeyCommands.scan(ScanCursor, ScanArgs)
-
touch
Long touch(K... keys)
Touch one or more keys with pipelining. Touch sets the last accessed time for a key. Non-exsitent keys wont get created. Cross-slot keys will result in multiple calls to the particular cluster nodes.- Specified by:
touch
in interfaceRedisKeyCommands<K,V>
- Parameters:
keys
- the keys- Returns:
- Long integer-reply the number of found keys.
-
-