[id='redis-commands_{context}']
= Redis commands

The {brandname} RESP endpoint implements the following Redis commands:


* link:https://redis.io/commands/append[APPEND]

* link:https://redis.io/commands/auth[AUTH]

* link:https://redis.io/commands/blpop[BLPOP]

* link:https://redis.io/docs/latest/commands/blmpop[BLMPOP]

* link:https://redis.io/commands/brpop[BRPOP]

* link:https://redis.io/commands/client-getname[CLIENT GETNAME]

* link:https://redis.io/commands/client-id[CLIENT ID]

* link:https://redis.io/commands/client-info[CLIENT INFO]

* link:https://redis.io/commands/client-list[CLIENT LIST]

* link:https://redis.io/commands/client-setinfo[CLIENT SETINFO]

* link:https://redis.io/commands/client-setname[CLIENT SETNAME]

* link:https://redis.io/commands/command[COMMAND]

* link:https://redis.io/commands/config[CONFIG]

* link:https://redis.io/docs/latest/commands/cluster-keyslot/[CLUSTER KEYSLOT]

* link:https://redis.io/commands/cluster-nodes/[CLUSTER NODES]
+
NOTE: This commands includes all required fields, but some fields are set to `0` as they do not apply to {brandname}.

* link:https://redis.io/commands/cluster-shards/[CLUSTER SHARDS]

* link:https://redis.io/commands/cluster-slots/[CLUSTER SLOTS]

* link:https://redis.io/commands/dbsize[DBSIZE]

* link:https://redis.io/commands/decr[DECR]

* link:https://redis.io/commands/decrby[DECRBY]

* link:https://redis.io/commands/del[DEL]

* link:https://redis.io/commands/discard[DISCARD]

* link:https://redis.io/commands/echo[ECHO]

* link:https://redis.io/commands/eval[EVAL]
+
NOTE: unlike Redis, which maintains a bounded cache of ephemeral scripts, {brandname} discards the script immediately after execution.

* link:https://redis.io/commands/eval_ro[EVAL_RO]
+
NOTE: unlike Redis, which maintains a bounded cache of ephemeral scripts, {brandname} discards the script immediately after execution.

* link:https://redis.io/commands/evalsha[EVALSHA]

* link:https://redis.io/commands/evalsha_ro[EVALSHA_RO]

* link:https://redis.io/commands/exec[EXEC]
+
See the xref:multi_command[MULTI] command.

* link:https://redis.io/commands/exists[EXISTS]

* link:https://redis.io/commands/expire[EXPIRE]

* link:https://redis.io/commands/expireat[EXPIREAT]

* link:https://redis.io/commands/expiretime[EXPIRETIME]

* link:https://redis.io/commands/flushall[FLUSHALL]
+
NOTE: This command behaves like `FLUSHDB` and flushes only the current database.

* link:https://redis.io/commands/flushdb[FLUSHDB]

* link:https://redis.io/commands/get[GET]

* link:https://redis.io/commands/getdel[GETDEL]

* link:https://redis.io/commands/getex[GETEX]

* link:https://redis.io/commands/getrange[GETRANGE]

* link:https://redis.io/commands/getset[GETSET]
+
NOTE: This command is deprecated. Use the `SET` command with the appropriate flags instead.

* link:https://redis.io/commands/hdel[HDEL]

* link:https://redis.io/commands/hello[HELLO]
+
NOTE: Only protocol version 3 (RESP3) is supported.

* link:https://redis.io/commands/hexists[HEXISTS]

* link:https://redis.io/commands/hget[HGET]

* link:https://redis.io/docs/latest/commands/hgetall[HGETALL]

* link:https://redis.io/commands/hincrby[HINCRBY]

* link:https://redis.io/commands/hincrbyfloat[HINCRBYFLOAT]

* link:https://redis.io/commands/hkeys[HKEYS]

* link:https://redis.io/commands/hlen[HLEN]

* link:https://redis.io/commands/hmget[HMGET]

* link:https://redis.io/commands/hmset[HMSET]

* link:https://redis.io/commands/hrandfield[HRANDFIELD]

* link:https://redis.io/commands/hscan[HSCAN]

* link:https://redis.io/commands/hset[HSET]

* link:https://redis.io/commands/hsetnx[HSETNX]

* link:https://redis.io/commands/hstrlen[HSTRLEN]

* link:https://redis.io/commands/hvals[HVALS]

* link:https://redis.io/commands/incr[INCR]

* link:https://redis.io/commands/incrby[INCRBY]

* link:https://redis.io/commands/incrbyfloat[INCRBYFLOAT]

* link:https://redis.io/commands/info[INFO]
+
NOTE: This implementation attempts to return all attributes that a real Redis server returns. However, in most cases, the values are set to `0` because they cannot be retrieved, or don't apply to {brandname}.

* link:https://redis.io/commands/json.arrappend[JSON.ARRAPPEND]

* link:https://redis.io/commands/json.arrindex[JSON.ARRINDEX]

* link:https://redis.io/commands/json.arrindex[JSON.ARRINSERT]

* link:https://redis.io/commands/json.arrlen[JSON.ARRLEN]

* link:https://redis.io/commands/json.arrtrim[JSON.ARRTRIM]

* link:https://redis.io/commands/json.clear[JSON.CLEAR]

* link:https://redis.io/commands/json.arrpop[JSON.ARRPOP]

* link:https://redis.io/commands/json.debug-memory[JSON.DEBUG MEMORY]

* link:https://redis.io/commands/json.del[JSON.DEL]

* link:https://redis.io/commands/json.forget[JSON.FORGET]

* link:https://redis.io/commands/json.get[JSON.GET]
+
[NOTE]
=====
 JSON filter with RegEx differencies from Redis implementation:

1. Pattern could be expressed in Redis style "(i)pattern" or Java style "/.*pattern.*/i)".
2. Dynamic filter with regex is not supported. i.e. `$.store.book[?(@.name =~ $.pattern)]` doesn't work.
3. Filtering an array returns all matching elements and all nested arrays containing matching elements.

=====

* link:https://redis.io/docs/latest/commands/json.merge [JSON.MERGE]

* link:https://redis.io/commands/json.mset[JSON.MSET]
+
NOTE: This command is non atomic

* link:https://redis.io/commands/json.mget[JSON.MGET]

* link:https://redis.io/commands/json.numincrby[JSON.NUMINCRBY]

* link:https://redis.io/commands/json.nummultby[JSON.NUMMULTBY]

* link:https://redis.io/commands/json.objkeys[JSON.OBJKEYS]

* link:https://redis.io/commands/json.objlen[JSON.OBJLEN]

* link:https://redis.io/docs/latest/commands/json.resp[JSON.RESP]

* link:https://redis.io/commands/json.set[JSON.SET]

* link:https://redis.io/commands/json.strappend[JSON.STRAPPEND]

* link:https://redis.io/commands/json.strlen[JSON.STRLEN]

* link:https://redis.io/commands/json.toggle[JSON.TOGGLE]

* link:https://redis.io/commands/json.type[JSON.TYPE]

* link:https://redis.io/commands/keys[KEYS]

* link:https://redis.io/commands/lindex[LINDEX]

* link:https://redis.io/commands/linsert[LINSERT]
+
NOTE: The current implementation has a time complexity of O(N), where N is the size of the list.

* link:https://redis.io/commands/llen[LLEN]

* link:https://redis.io/commands/lcs[LCS]

* link:https://redis.io/commands/lmove[LMOVE]
+
NOTE: The current implementation is atomic for rotation when the source and destination are the same list. For different lists, there is relaxed consistency for concurrent operations or failures unless the resp cache is configured to use transactions.

* link:https://redis.io/commands/lmpop[LMPOP]

* link:https://redis.io/commands/lpop[LPOP]

* link:https://redis.io/commands/lpos[LPOS]

* link:https://redis.io/commands/lpush[LPUSH]

* link:https://redis.io/commands/lpushx[LPUSHX]

* link:https://redis.io/commands/lrange[LRANGE]

* link:https://redis.io/commands/lrem[LREM]

* link:https://redis.io/commands/lset[LSET]

* link:https://redis.io/commands/ltrim[LTRIM]

* link:https://redis.io/commands/memory-info[MEMORY USAGE]
+
NOTE: This command will return the memory used by the key and the value. It doesn't include the memory used by additional metadata associated with the entry.

* link:https://redis.io/commands/memory-stats[MEMORY STATS]
+
NOTE: This command will return the same fields as a real Redis server, but all values will be set to `0`.

* link:https://redis.io/commands/mget[MGET]

* link:https://redis.io/commands/module-list[MODULE LIST]
+
NOTE: This command always returns an empty list of modules.

* link:https://redis.io/commands/mset[MSET]

* link:https://redis.io/commands/msetnx[MSETNX]

* link:https://redis.io/commands/multi[MULTI] [[multi_command]]
+
NOTE: The current implementation has a relaxed isolation level. Redis offers serializable transactions.

* link:https://redis.io/commands/persist[PERSIST]

* link:https://redis.io/docs/latest/commands/pfadd[PFADD]

* link:https://redis.io/commands/pexpire[PEXPIRE]

* link:https://redis.io/docs/latest/commands/pexpireat[PEXPIREAT]

* link:https://redis.io/commands/pexpiretime[PEXPIRETIME]

* link:https://redis.io/commands/ping[PING]

* link:https://redis.io/commands/psetex[PSETEX]
+
NOTE: This command is deprecated. Use the `SET` command with the appropriate flags.

* link:https://redis.io/commands/psubscribe[PSUBSCRIBE]

* link:https://redis.io/docs/latest/commands/pubsub-channels[PUBSUB CHANNELS]

* link:https://redis.io/docs/latest/commands/pubsub-numpat[PUBSUB NUMPAT]

* link:https://redis.io/commands/pttl[PTTL]

* link:https://redis.io/commands/publish[PUBLISH]

* link:https://redis.io/commands/punsubscribe[PUNSUBSCRIBE]

* link:https://redis.io/commands/quit[QUIT]

* link:https://redis.io/commands/randomkey[RANDOMKEY]

* link:https://redis.io/commands/rpop[RPOP]

* link:https://redis.io/commands/rpoplpush[RPOPLPUSH]

* link:https://redis.io/commands/rpush[RPUSH]

* link:https://redis.io/commands/rpushx[RPUSHX]

* link:https://redis.io/commands/readonly[READONLY]

* link:https://redis.io/commands/readwrite[READWRITE]

* link:https://redis.io/commands/rename[RENAME]

* link:https://redis.io/commands/renamenx[RENAMENX]

* link:https://redis.io/commands/reset[RESET]

* link:https://redis.io/commands/sadd[SADD]

* link:https://redis.io/commands/scard[SCARD]

* link:https://redis.io/commands/scan[SCAN]
+
NOTE: Cursors are reaped in case they have not been used within a timeout. The timeout is 5 minutes.

* link:https://redis.io/commands/script-exists[SCRIPT EXISTS]

* link:https://redis.io/commands/script-flush[SCRIPT FLUSH]

* link:https://redis.io/commands/script-load[SCRIPT LOAD]

* link:https://redis.io/commands/sdiff[SDIFF]

* link:https://redis.io/commands/sdiffstore[SDIFFSTORE]

* link:https://redis.io/commands/select[SELECT]
+
NOTE: {brandname} allows the SELECT command both in local and clustered mode, unlike Redis Cluster which forbids use of this command and only supports database zero.

* link:https://redis.io/commands/set[SET]

* link:https://redis.io/commands/setex[SETEX]
+
NOTE: This command is deprecated. Use the `SET` command with the appropriate flags instead.

* link:https://redis.io/commands/setnx[SETNX]
+
NOTE: This command is deprecated. Use the `SET` command with the appropriate flags instead.

* link:https://redis.io/commands/set[SETRANGE]

* link:https://redis.io/commands/sinter[SINTER]

* link:https://redis.io/commands/sintercard[SINTERCARD]

* link:https://redis.io/commands/sinterstore[SINTERSTORE]

* link:https://redis.io/commands/sismember[SISMEMBER]

* link:https://redis.io/commands/sort[SORT]

* link:https://redis.io/commands/sort_ro[SORT_RO]

* link:https://redis.io/commands/members[SMEMBERS]

* link:https://redis.io/commands/smismember[SMISMEMBER]

* link:https://redis.io/commands/smove[SMOVE]
+
NOTE: The current implementation has a relaxed isolation level. A client can see the source and destination set without
the element. The operation is not atomic, it could remove the element from source and fails to insert to the target set.

* link:https://redis.io/commands/spop[SPOP]

* link:https://redis.io/commands/srandmember[SRANDMEMBER]

* https://redis.io/docs/latest/commands/srem[SREM]

* link:https://redis.io/commands/sscan[SSCAN]

* link:https://redis.io/commands/lcs[STRALGO LCS]

* link:https://redis.io/commands/strlen[STRLEN]

* link:https://redis.io/commands/substr[SUBSTR]
+
NOTE: This command is deprecated. Use the `GETRANGE` command instead.

* link:https://redis.io/commands/subscribe[SUBSCRIBE]

* link:https://redis.io/commands/sunion[SUNION]

* link:https://redis.io/commands/sunionstore[SUNIONSTORE]

* link:https://redis.io/commands/time[TIME]

* link:https://redis.io/docs/latest/commands/touch[TOUCH]

* link:https://redis.io/commands/ttl[TTL]

* link:https://redis.io/commands/type[TYPE]

* link:https://redis.io/commands/unsubscribe[UNSUBSCRIBE]

* link:https://redis.io/commands/unwatch[UNWATCH]

* link:https://redis.io/commands/watch[WATCH]

* link:https://redis.io/commands/zadd[ZADD]

* link:https://redis.io/commands/zcard[ZCARD]

* link:https://redis.io/commands/zcount[ZCOUNT]

* link:https://redis.io/commands/zdiff[ZDIFF]

* link:https://redis.io/commands/zdiffstore[ZDIFFSTORE]

* link:https://redis.io/commands/zincrby[ZINCRBY]

* link:https://redis.io/commands/zinter[ZINTER]

* link:https://redis.io/commands/zintercard[ZINTERCARD]

* link:https://redis.io/commands/zinterstore[ZINTERSTORE]

* link:https://redis.io/commands/zlexcount[ZLEXCOUNT]

* link:https://redis.io/commands/zmpop[ZMPOP]

* link:https://redis.io/docs/latest/commands/zmscore[ZMSCORE]

* link:https://redis.io/commands/zpopmax[ZPOPMAX]

* link:https://redis.io/commands/zpopmin[ZPOPMIN]

* link:https://redis.io/commands/zunion[ZUNION]

* link:https://redis.io/commands/zunionstore[ZUNIONSTORE]

* link:https://redis.io/commands/zrandmember[ZRANDMEMBER]

* link:https://redis.io/commands/zrange[ZRANGE]

* link:https://redis.io/commands/zrangebylex[ZRANGEBYLEX]

* link:https://redis.io/commands/zrangebyscore[ZRANGEBYSCORE]

* link:https://redis.io/commands/zrevrange[ZREVRANGE]

* link:https://redis.io/commands/zrevrangebylex[ZREVRANGEBYLEX]

* link:https://redis.io/commands/zrevrangebyscore[ZREVRANGEBYSCORE]

* link:https://redis.io/commands/zrangestore[ZRANGESTORE]

* https://redis.io/docs/latest/commands/zrank[ZRANK]

* link:https://redis.io/commands/zrem[ZREM]

* link:https://redis.io/commands/zremrangebylex[ZREMRANGEBYLEX]

* link:https://redis.io/commands/zremrangebyrank[ZREMRANGEBYRANK]

* link:https://redis.io/commands/zremrangebyscore[ZREMRANGEBYSCORE]

* link:https://redis.io/docs/latest/commands/zrevrank[ZREVRANK]

* link:https://redis.io/commands/zscore[ZSCAN]

* link:https://redis.io/commands/zscore[ZSCORE]
