Introduction

What is FyroDB and why it exists.

What is FyroDB?

FyroDB is a Redis-compatible in-memory key-value store written in Rust. It speaks the RESP protocol — any Redis client, SDK, or CLI tool works without modification.

Unlike Redis (single-threaded), FyroDB uses all CPU cores via a thread-per-core architecture with a fully lock-free concurrent hash map and per-key seqlock. A single FyroDB node outperforms a 6-node Redis Cluster on every workload.

Key Features

  • Redis-compatible — drop-in replacement, supports all major data types and 150+ commands
  • Lock-free reads — epoch-based reclamation, seqlock validation for iteration safety
  • Zero-clone writes — per-key spinlock with in-place mutation, no CAS retry loops
  • Thread-per-core — one epoll loop per CPU, SO_REUSEPORT kernel accept
  • Zero-copy GET — writes directly from stored value to TCP buffer
  • Full data type support — String, Hash, List, Set, Sorted Set, JSON, Stream, Bitmap, HyperLogLog, Geospatial
  • RDB persistence — automatic snapshots, atomic saves, crash-safe
  • Pub/Sub — 29.26M msg/sec delivery with lock-free Arc snapshots

Performance

BenchmarkFyroDB (1 node)Redis Cluster (6 nodes)Speedup
Pipeline-64 SET~14.7M ops/sec~3.5M ops/sec4.2×
Pipeline-100 SET~14.9M ops/sec~7.9M ops/sec1.9×
Pipeline-100 GET~20.05M ops/sec~8.3M ops/sec2.4×
Mixed SET/GET~21.05M ops/sec~3.11M ops/sec6.8×
INCR (counters)~34.09M ops/sec~3.96M ops/sec8.6×
HSET/HGET~17.07M ops/sec~3.52M ops/sec4.8×
LPUSH/RPOP~31.93M ops/sec~3.64M ops/sec8.8×
SADD~17.13M ops/sec~2.84M ops/sec6.0×
ZADD~7.95M ops/sec~2.30M ops/sec3.5×
JSON.SET/GET~5.41M ops/sec~1.69M ops/sec3.2×
SET+EXPIRE~12.13M ops/sec~1.85M ops/sec6.6×
Hot Key (contention)~23.00M ops/sec~1.65M ops/sec13.9×
Pub/Sub delivery~29.26M msg/sec~6.03M msg/sec4.9×
Producer/Consumer~3.03M ops/sec~833.6K ops/sec3.6×

Links