命令族 | 命令 | 新增说明 |
keys 族 | EXPIRETIME key | 新增命令。 返回 key 过期时间的秒级时间戳。 |
| PEXPIRETIME key | 新增命令。 返回 key 过期时间的毫秒级时间戳。 |
| EXPIRE key seconds [NX | XX | GT | LT] | 新增 NX | XX | GT | LT参数。 NX 只当 key 不存过期时间的时候,设置过期时间。 XX 只当 key 存在过期时间的时候,设置过期时间。 GT 只当新的过期时间比当前过期时间更大的时候,设置新的过期时间。 LT 只当新的过期时间比当前过期时间更小的时候,设置新的过期时间。 |
| SORT_RO key [BY pattern] [LIMIT offset count] [GET pattern [GET pattern ...]] [ASC | DESC] [ALPHA] | 新增命令。 对 Redis 中的有序集合(sorted set)进行排序并获取排序后的结果。 |
命令 | 2.8 内存版(标准架构) | 4.0 内存版(标准架构) | 4.0 内存版(集群架构) | 5.0 内存版(标准架构) | 5.0 内存版(集群架构) |
6.2 内存版(标准架构)
|
6.2 内存版(集群架构)
|
7.0 内存版(标准架构)
|
7.0 内存版(集群架构)
| 内存版(集群架构)跨 Slot 支持 |
touch | x | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
restore | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
object | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
object help | x | x | x | x | x | ✓ | ✓ | ✓ | ✓ | - |
unlink | x | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | x |
wait | x | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
migrate | x | x | x | x | x | x | x | x | x | - |
dump | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
del | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
scan | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
exists | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
expire | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
expireat | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
keys | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
type | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
move | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
ttl | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
persist | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
pexpire | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
pexpireat | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
pttl | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
randomkey | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
rename | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | x |
renamenx | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | x |
sort | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | - |
sort_ro | x | x | x | x | x | x | x | ✓ | ✓ | - |
copy | x | x | x | x | x | ✓ | ✓ | ✓ | ✓ | - |
expiretime | x | x | x | x | x | x | x | ✓ | ✓ | - |
pexpiretime | x | x | x | x | x | x | x | ✓ | ✓ | - |
本页内容是否解决了您的问题?