I got tired of Redis and Kafka eating my RAM, so I rebuilt them in Rust hitting 1.6M RPS (as a student)
Hey everyone, I’m Yasir. I’m an 18-year-old software engineering student from Pakistan, and for the last few months, I’ve been going down a very deep, very complex rabbit hole: Systems Programming in Rust . When I started learning about distributed systems , I noticed a recurring theme: tools like Apache Kafka and Redis are absolute industry standards, but they come with a catch. Kafka relies…
Yasir, an 18-year-old software engineering student from Pakistan, decided to tackle a challenging project in the world of Systems Programming in Rust. He observed that popular distributed system tools like Apache Kafka and Redis had limitations, such as high memory footprints and performance bottlenecks. To overcome these issues, Yasir set out to create his own infrastructure pieces, Velocity-MQ and VelocityDB, both built entirely from scratch in Rust.
Velocity-MQ is a zero-GC, lock-free message queue (a Kafka alternative), while VelocityDB is a thread-per-core, lock-free in-memory store (a Redis alternative). The key to VelocityDB's exceptional performance lies in its architecture, which includes bypassing the Kernel with io_uring for asynchronous I/O, a thread-per-core model to avoid contention and locks, and lock-free concurrency using ring buffers and atomic pointers.
These design choices resulted in VelocityDB reaching 1.6 million requests per second (RPS) on Yasir's local machine.
Despite being a first-semester CS student, Yasir is eager to engage with the community and welcome feedback on his code. He invites senior Rustaceans, systems engineers, and high-performance backend enthusiasts to review his work, point out any memory ordering flaws, and report bugs. You can find the project on GitHub (https://github.com/developer-yasir/). If you find the project interesting or helpful, Yasir would appreciate a star on the repository to keep him motivated for future developments.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.