All projects
May 2025
QuarkCache — Redis-like In-Memory Store Built in C++17
Systems ProgrammingLow-LatencyDistributed SystemsDevOps

- Built a Redis-style in-memory cache from scratch in C++ — the same eviction, expiry, and networking techniques production systems use — to understand exactly what makes them fast.
- O(1) LRU eviction via doubly-linked list + unordered_map; std::list::splice() promotes nodes with zero allocation — ~80K ops/sec on local TCP.
- Non-blocking TCP server using epoll/kqueue in edge-triggered mode handles 10K+ concurrent connections on a single thread, no context-switch overhead.
- Hybrid TTL expiry: lazy O(1) deletion on access + background sweep every 5s via steady_clock, mirroring Redis's production expiry strategy.
C++17epoll/kqueueFastAPIPythonNext.jsTypeScriptDockerCMake
