Motivation: Implement ByteByteGo-style system design projects to practice building scalable distributed systems from scratch while writing clean, production-ready Go code and React frontends.
Goal: Build a simple key-value store with an in-memory data model, append-only log for durability, and a minimal React/TypeScript UI to interact with it.
- In-Memory KV Store – Thread-safe hash map protected by RWMutex for concurrent reads/writes.
- API Design – Simple RESTful endpoints:
PUT /kv/{key},GET /kv/{key},DELETE /kv/{key},GET /healthz. - Frontend Integration – React + Vite frontend calling the Go API via
/apiproxy, with typed API client and minimal UI. - CORS Middleware – Global middleware ensures proper cross-origin support between frontend and backend.
flowchart LR
UI[React UI] --> | fetch /api/kv/:key | API(Go HTTP Server)
UI --> | PUT /api/kv/:key | API
UI --> | DELETE /api/kv/:key | API
API --> | in-mem calls | Store[(Store: KV Pairs)]
API --> | JSON | UI
classDef dim fill:#eee,stroke:#bbb,color:#777;