Benchmarks

Reproducible

All benchmarks are run using open-source tooling with documented methodology. Configuration files and scripts are available in the benchmarks/ directory of the repository.

Overview

DbSync is designed to outperform existing key-value stores on multi-core hardware. This page presents comprehensive benchmark results comparing DbSync against Redis 7.2 and DragonflyDB 1.14.


Methodology

All tests follow a standardized methodology to ensure fair comparison:

ParameterValue
Toolmemtier_benchmark v1.4.0
Clients200 concurrent connections
Threads8 benchmark threads
Payload32-byte values
Ratio1:1 SET/GET
PipeliningEnabled (sustained-throughput run)
Duration60 seconds per run

Each engine was configured with equivalent resources and tuned according to official production recommendations.


Test Hardware

ComponentSpecification
CPUx86_64 — 8 physical cores / 16 threads
Reactors8 (pinned one per physical core)
NetworkLoopback (127.0.0.1)
OSLinux, kernel 6.8
Note

Client and server run on the same host over loopback. DbSync pins one reactor per physical core, skipping hyper-threaded siblings for cache locality.


Throughput Results

Head-to-Head (8 threads, 200 clients, 1:1 SET/GET, 60s)

EngineOps/secvs Redis
DbSync (Async AOF)2,140,143+74.7%
Redis 7.21,225,170baseline
DragonflyDB 1.141,161,721−5.2%
Where the gap comes from

DbSync coalesces every SET into a single batched, fire-and-forget io_uring write per event-loop iteration instead of gating each response on its own synchronous append. Combined with the zero-copy RESP parser and batched io_uring submissions — each io_uring_enter() submits the whole batch in one syscall — this roughly doubles mixed-workload throughput over Redis and DragonflyDB.


Latency Results

Latency Distribution

EngineP50 (ms)P99 (ms)P99.9 (ms)
DbSync (Async AOF)10.5634.0560.16
Redis 7.219.5841.4754.02
DragonflyDB 1.1418.3075.78108.03
Notice

At ~2.1M ops/sec DbSync holds the lowest median and P99 latency of the three — roughly half of DragonflyDB's P99. Redis edges ahead only at the extreme P99.9 tail (54.0 ms vs 60.2 ms), a ~0.1%-of-requests effect from the async AOF batch flush occasionally landing in front of a request.

Tip

Because each reactor owns its data shard and its own connections, tail latency stays bounded under load — there's no shared accept queue, global connection list, or lock contention to spike P99.


Scalability

DbSync uses a shared-nothing design: each reactor thread is pinned to a physical core and owns a private partition of the keyspace, so throughput scales with core count without lock contention on the hot path. On this 8-core host the mixed 1:1 workload sustains ~2.14M ops/sec, and a pipelined SET-only load reaches ~2.0M ops/sec.

Note

Cross-shard requests (a connection on reactor A touching a key owned by reactor B) are forwarded over a lock-free SPSC bus with eventfd signaling, so steering adds a hop rather than a lock. Pinning one reactor per physical core (skipping hyper-threaded siblings) preserves L1/L2 cache warmth.


Run Your Own Benchmarks

Clone the repository and run make bench to reproduce these results on your own hardware. The benchmark suite automatically downloads and configures all three engines.

git clone https://github.com/Ayush-Vish/Dbsync.git
cd Dbsync
make bench