分布式缓存服务经典版Redis5.0基于开源5.0.5版本进行开发,兼容开源的协议和命令,支持Redis的绝大部分命令,任何兼容Redis协议的客户端都可以访问Redis实例。分布式缓存基础版Redis5.0基于开源5.0.5二次开发,兼容开源的协议和命令,支持Redis的全部命令。本章节介绍2.8/4.0/5.0经典版单机、主备、集群单机、集群主备支持和不支持/禁用的命令。
经典版单机/主备支持的命令清单
Key |
String |
List |
Set |
SortedSet |
Hash |
Server |
del |
append |
blpop |
sadd |
zadd |
hdel |
del |
dump |
bitcount |
brpop |
scard |
zcard |
hexists |
dump |
exists |
bitop |
brpoplrush |
sdiff |
zcount |
hget |
exists |
expire |
bitpos |
lindex |
sdiffstore |
zincrby |
hgetall |
expire |
move |
decr |
linsert |
sinter |
zrange |
hincrby |
move |
persist |
decrby |
llen |
sinterstore |
zrangebyscore |
hincrbyfloat |
persist |
pttl |
get |
lpop |
sismember |
zrank |
hkeys |
pttl |
randomkey |
getrange |
lpushx |
smembers |
zremrangebyrank |
hmget |
randomkey |
rename |
getset |
lrange |
smove |
zremrangebycore |
hmset |
rename |
renamenx |
incr |
lrem |
spop |
zrevrange |
hset |
renamenx |
restore |
incrby |
lset |
srandmember |
zrevrangebyscore |
hsetnx |
restore |
sort |
incrbyfloat |
ltrim |
srem |
zrevrank |
hvals |
sort |
ttl |
mget |
rpop |
sunion |
zscore |
hscan |
ttl |
type |
mset |
rpoplpu |
sunionstore |
zunionstore |
hstrlen |
type |
scan |
msetnx |
rpoplpush |
sscan |
zinterstore |
hlen |
scan |
object |
psetex |
rpush |
- |
zscan |
- |
object |
pexpireat |
set |
rpushx |
- |
zrangebylex |
- |
pexpireat |
pexpire |
setbit |
lpush |
- |
zlexcount |
- |
pexpire |
- |
setex |
- |
- |
zpopmin |
- |
- |
- |
setnx |
- |
- |
zpopmax |
- |
- |
- |
setrange |
- |
- |
zremrangebyscore |
- |
- |
- |
strlen |
- |
- |
zrem |
- |
- |
- |
bitfield |
- |
- |
- |
- |
- |
HyperLoglog |
Pub/Sub |
Transactions |
Connection |
Scripting |
Geo |
Stream |
pfadd |
psubscribe |
discard |
auth |
eval |
geoadd |
xack |
pfcount |
publish |
exec |
echo |
evalsha |
geohash |
xadd |
pfmerge |
pubsub |
multi |
ping |
script exists |
geopos |
xclaim |
- |
punsubscribe |
unwatch |
quit |
script flush |
geodist |
xdel |
- |
subscribe |
watch |
select(cluster集群实例不支持) |
script kill |
georadius |
xgroup |
- |
unsubscribe |
- |
- |
script load |
georadiusbymember |
xinfo |
- |
- |
- |
- |
- |
- |
xlen |
- |
- |
- |
- |
- |
- |
xpending |
- |
- |
- |
- |
- |
- |
xrange |
- |
- |
- |
- |
- |
- |
xread |
- |
- |
- |
- |
- |
- |
xreadgroup |
- |
- |
- |
- |
- |
- |
xrevrange |
- |
- |
- |
- |
- |
- |
xtrim |
经典版集群单机/主备支持的命令清单
Key |
String |
List |
Set |
SortedSet |
Hash |
exists |
set |
lpop |
sadd |
zadd |
hdel |
del |
get |
lpush |
scard |
zcard |
hexists |
type |
strlen |
llen |
sismember |
zcount |
hget |
expire |
append |
lrange |
smembers |
zincrby |
hgetAll |
persist |
decrBy |
rpop |
srem |
zrange |
hkeys |
ttl |
decr |
rpush |
spop |
zrangeWithScores |
hlen |
pexpire |
incr |
lindex |
sscan |
zrangeByScore |
hmget |
pttl |
incrBy |
linsert |
- |
zrem |
hmset |
lock |
getrange |
lpushx |
- |
zscore |
hset |
unlock |
getSet |
lrem |
- |
zremrangeByRank |
hsetnx |
scan |
setex |
lset |
- |
zremrangeByScore |
hincrBy |
dump |
setnx |
ltrim |
- |
zrank |
hvals |
expireat |
setrange |
rpushx |
- |
zrevrange |
hincrbyfloat |
move |
bitcount |
- |
- |
zrevrangebyscore |
hstrlen |
object |
bitpos |
- |
- |
zrevrank |
- |
pexpireat |
getbit |
- |
- |
zscan |
- |
randomkey |
psetex |
- |
- |
zrangebylex |
- |
restore |
setbit |
- |
- |
zlexcount |
- |
sort |
mget |
- |
- |
zremrangebylex |
- |
keys |
mset |
- |
- |
ZPOPMAX |
- |
unlink |
- |
- |
- |
ZPOPMIN |
- |
Connection |
GEO |
Server |
Streams |
Pub/Sub |
auth |
geoadd |
flushdb |
XADD |
publish |
ping |
geohash |
dbsize |
XDEL |
Subscribe |
select |
geopos |
client list |
XLEN |
unsubscribe |
echo |
geodist |
Client kill |
XRANGE |
Pubsub |
quit |
georadius |
- |
XREVRANGE |
psubscribe |
- |
georadiusbymember |
- |
XPENDING |
punsubscribe |
- |
- |
- |
XACK |
- |
- |
- |
- |
XCLAIM |
- |
- |
- |
- |
XTRIM |
- |
- |
- |
- |
XGROUP |
- |
- |
- |
- |
XINFO |
- |
经典版单机/主备禁用的命令清单
Server |
save |
bgsave |
bgrewriteaof |
sync |
psync |
经典版集群单机/主备禁用的命令清单
Key |
Script |
Server |
HyperLogLog |
Connection |
Transactions |
wait |
eval |
bgrewriteaof |
pfcount |
swapdb |
discard |
migrate |
evalsha |
bgsave |
pfmerge |
- |
exec |
rename |
script exists |
client getname |
- |
- |
multi |
renamenx |
script flush |
client kill |
- |
- |
unwatch |
touch |
script kill |
client setname |
- |
- |
watch |
- |
script load |
config get |
- |
- |
- |
- |
- |
config resetstat |
- |
- |
- |
- |
- |
config rewrite |
- |
- |
- |
- |
- |
config set |
- |
- |
- |
- |
- |
debug object |
- |
- |
- |
- |
- |
debug segfault |
- |
- |
- |
- |
- |
flushall |
- |
- |
- |
- |
- |
info |
- |
- |
- |
- |
- |
lastsave |
- |
- |
- |
- |
- |
monitor |
- |
- |
- |
- |
- |
psync |
- |
- |
- |
- |
- |
save |
- |
- |
- |
- |
- |
shutdown |
- |
- |
- |
- |
- |
slaveof |
- |
- |
- |
- |
- |
slowlog |
- |
- |
- |
- |
- |
sync |
- |
- |
- |
- |
- |
time |
- |
- |
- |
List |
Set |
Sorted Set |
Streams |
Cluster |
blpop |
smove |
bzpopmin |
xread |
所有cluster命令皆不支持 |
brpop |
srandmember |
bzpopmax |
xreadgroup |
- |
brpoplpush |
- |
zinterstore |
- |
- |
rpoplpush |
- |
zrevrangebylex |
- |
- |
- |
- |
zunionstore |
- |
- |