Question: How fast is Redis?
Answer
Redis is known for its speed and high performance. It is an in-memory data structure store that can perform millions of operations per second. Redis achieves this by using an optimized, single-threaded architecture and by keeping all data in memory.
Here are some benchmarks that demonstrate Redis's speed:
- Redis can do around 110,000 SETs per second on a entry-level laptop.
127.0.0.1:6379> benchmark set 100000 SET: 108695.65 requests per second
- Redis can handle up to 1 million SETs per second on a powerful server.
127.0.0.1:6379> benchmark set 10000000 SET: 1000000.00 requests per second
- Redis can fetch 81,000 values per second with pipelining enabled.
127.0.0.1:6379> benchmark -t get -n 100000 -P 8 GET: 81037.34 requests per second
- Redis can process more than 1 million transactions per second with multi-exec commands.
127.0.0.1:6379> benchmark -t set,get,multi_exec -n 1000000 SET: 657894.74 requests per second GET: 1234567.75 requests per second MULTI_EXEC: 1157407.41 requests per second
It's worth noting that these benchmarks were performed on a local machine, and your mileage may vary depending on your hardware, network topology, and workload. However, the benchmarks provide a good indication of Redis's performance.
Was this content helpful?
Other Common Redis Questions (and Answers)
Free System Design on AWS E-Book
Download this early release of O'Reilly's latest cloud infrastructure e-book: System Design on AWS.
Switch & save up to 80%
Dragonfly is fully compatible with the Redis ecosystem and requires no code changes to implement. Instantly experience up to a 25X boost in performance and 80% reduction in cost