Reddish
Reddish - a minimal Redis-like server written in C++
Install / Use
/learn @amitverma-cf/ReddishREADME
reddish
reddish - a minimal Redis-like server written in C++17.
It supports:
- string, list, and hash commands
- RESP command parsing
- multi-client TCP server
- periodic and shutdown persistence (
dump.reddish)
Build
Recommended (MSVC preset)
cmake --preset msvc-release
cmake --build --preset build-release
Binary:
build/msvc-release/output/reddish.exe
Generic CMake
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build
Binary:
build/output/reddishbuild/output/reddish.exe
Run
./build/output/reddish
Or with custom port:
./build/output/reddish 6389
Documentation
Generate API docs:
cmake --preset msvc-release
cmake --build build/msvc-release --target docs
Output:
docs/html/index.html
Theme:
doxygen-awesome-css(fetched by CMake during configure)
Project layout
src/NetworkApi.hpp/src/NetworkApi.cpp: cross-platform socket helperssrc/Server.hpp/src/Server.cpp: TCP accept loop and client thread handlingsrc/CommandHandler.hpp/src/CommandHandler.cpp: command parsing and dispatchsrc/Database.hpp/src/Database.cpp: in-memory storage and persistencesrc/main.cpp: startup and background persistence thread
Notes
- Build system is CMake-based; use
CMakePresets.jsonfor local setup. Threads::Threadsis intentionally linked for portable thread support.
