Skip to content

Goose97/tiny-redis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

What is this project?

This project serves as Rust learning materials.

Support commands

  1. Generic commands
  • DEL
  • EXPIRE
  • TTL
  • EXISTS
  • FLUSH
  1. String commands
  • GET
  • SET
  • SETNX
  • MGET
  • MSET
  • GETSET
  • GETDEL
  • INCR
  • DECR
  • INCRBY
  • DECRBY
  1. List commands
  • LPOP
  • RPOP
  • LPUSH
  • RPUSH
  • LLEN
  • LRANGE
  • LREM
  • LSET
  • LTRIM
  • BLPOP
  • BRPOP
  1. Hash commands
  • HLEN
  • HKEYS
  • HGET
  • HMGET
  • HGETALL
  • HINCRBY
  • HSET
  • HMSET
  • HSETNX

Benchmark

We use redis-benchmark (shipped with Redis) as our go to benchmark tool. To benchmark, simply run:

bash script/bench.sh

The test suite simulates 100 clients, each makes 100000 requests. Under the hood, we run this:

redis-benchmark -h localhost -p <port> -c 100 -n 100000 -k 1 -t <commands> --csv
Command redis (op/s) tiny_redis (op/s) Comparison
GET 89445.44 58038.3 ❌ -35.11%
SET 87260.03 54614.96 ❌ -37.41%
INCR 88888.89 57870.37 ❌ -34.90%
LPOP 80710.25 59772.86 ❌ -25.94%
RPOP 86430.43 52576.24 ❌ -39.17%
LPUSH 93896.71 61012.81 ❌ -35.02%
RPUSH 91157.7 62656.64 ❌ -31.27%

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published