You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A production-grade, microservices-based university enrollment system designed to handle flash-sale traffic patterns at 10,000+ RPS with zero overbooking.
Architecture
Frontend (React) → API Gateway (Spring Cloud Gateway)
│ Token Bucket Rate Limiter
├─→ Enrollment Service (Spring Boot + Virtual Threads)
│ Redis Lua: Seat Reservation + Idempotency
│ Kafka Produce → enrollment_reserved
│
└─→ Course Service (Spring Boot + JPA)
CRUD, Search, Analytics, User Management
Kafka (6 partitions) → Enrollment Worker (Batch Consumer)
Batch UPSERT to PostgreSQL (200 rows/batch)
DLQ routing on failure → enrollment_dlq
Component
Technology
Purpose
API Gateway
Spring Cloud Gateway
Rate limiting (Token Bucket), routing, CORS
Enrollment Service
Spring Boot 3.3 + Java 21 Virtual Threads
Hot path: idempotency → seat reservation → Kafka produce
Enrollment Worker
Spring Boot 3.3 + Spring Kafka
Batched Kafka consumer → PostgreSQL UPSERT
Course Service
Spring Boot 3.3 + Spring Data JPA
CRUD, substring search, analytics, user management
Frontend
React 18 + Vite
Course catalog, enrollment, admin dashboard
Database
PostgreSQL 15
Persistent storage for users, courses, enrollments