This is a simple in-memory key-value store written in Go. All the commands are redis compatible (can be used via Redis CLI or any redis library), but the full redis 7.0 spec has not been implemented. This is not production ready. It was built as a learning exercise to better understand redis internals. I used a number of resources to learn how redis works in order to built GoKV that can be found here.
- PING
- SET
- DEL
- RANDOMKEY
- EXISTS
- STRLEN
- LOLWUT
- FLUSHALL
- GETSET
- SETNX
- INCR
- INCRBY
- DECR
- DECRBY
- RENAME
- RENAMENX
- HSET
- HGET
- HEXISTS
- HSTRLEN
- HLEN
- HGETALL
- HSETNX
- HDEL
- LPUSH
- LPOP
- RPOP
- LLEN
- RPUSH
- LINDEX
- LTRIM
- LRANGE
- LREM
- LSET
- DBSIZE
- MGET
$ redis-benchmark -t set,get, -n 100000 -q
SET: 92250.92 requests per second, p50=0.271 msec
GET: 93632.96 requests per second, p50=0.271 msec