Skip to content

Commit 7dbb7f0

Browse files
committed
feature: added new redis 2.8.0 commands: scan, sscan, hscan, and zscan. thanks Dragonoid for the patch in openresty#36.
1 parent 6c4c570 commit 7dbb7f0

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

lib/resty/redis.lua

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ if not ok then
1919
end
2020

2121

22-
local _M = new_tab(0, 151)
22+
local _M = new_tab(0, 155)
2323
_M._VERSION = '0.19'
2424

2525

@@ -39,7 +39,8 @@ local commands = {
3939
"hexists", "hget", "hgetall",
4040
"hincrby", "hincrbyfloat", "hkeys",
4141
"hlen",
42-
"hmget", --[[ "hmset", ]] "hset",
42+
"hmget", --[[ "hmset", ]] "hscan",
43+
"hset",
4344
"hsetnx", "hvals", "incr",
4445
"incrby", "incrbyfloat", "info",
4546
"keys",
@@ -59,14 +60,15 @@ local commands = {
5960
"restore",
6061
"rpop", "rpoplpush", "rpush",
6162
"rpushx", "sadd", "save",
62-
"scard", "script",
63+
"scan", "scard", "script",
6364
"sdiff", "sdiffstore",
6465
"select", "set", "setbit",
6566
"setex", "setnx", "setrange",
6667
"shutdown", "sinter", "sinterstore",
6768
"sismember", "slaveof", "slowlog",
6869
"smembers", "smove", "sort",
6970
"spop", "srandmember", "srem",
71+
"sscan",
7072
"strlen", "subscribe", "sunion",
7173
"sunionstore", "sync", "time",
7274
"ttl",
@@ -76,6 +78,7 @@ local commands = {
7678
"zrange", "zrangebyscore", "zrank",
7779
"zrem", "zremrangebyrank", "zremrangebyscore",
7880
"zrevrange", "zrevrangebyscore", "zrevrank",
81+
"zscan",
7982
"zscore", "zunionstore", "evalsha"
8083
}
8184

t/count.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ __DATA__
4040
--- request
4141
GET /t
4242
--- response_body
43-
size: 151
43+
size: 155
4444
--- no_error_log
4545
[error]
4646

0 commit comments

Comments
 (0)