High-level topology

┌─────────────────┐ │ React Web App │ │ Admin + Parent │ └────────┬────────┘ │ HTTPS ┌────────▼────────┐ │ api-gateway │ JWT, rate limit, CORS └────────┬────────┘ ┌───────────────────┼───────────────────┐ │ │ │ auth-service organization-service student-service fee-service finance-service academic-service attendance inventory-service notice-service health-service notification file-service report-service │ │ │ └───────────────────┼───────────────────┘ │ ┌──────────────┼──────────────┐ │ │ │ PostgreSQL RabbitMQ MinIO (per service) (events) (files)

Microservices

ServicePort (dev)DatabaseResponsibility
api-gateway8080Route, JWT validation, request logging
auth-service8081auth_dbUsers, roles, parent accounts, guardian links, JWT issue
organization-service8082org_dbSchool, campuses, academic years, terms, classes
student-service8083student_dbStudents, guardians, enrollments, requirements checklist
fee-service8084fee_dbFee structures, invoices, payment claims, payments, receipts, defaulters
finance-service8085finance_dbChart of accounts, journal entries, P&L, balance sheet
academic-service8086academic_dbSubjects, marks, grading schemes, report cards, homework
attendance-service8087attendance_dbDaily attendance, summaries
health-service8093health_dbStudent health records, parent confirmation, doctor's notes, nurse access, audit log
inventory-service8088inventory_dbStock, uniforms, issuance
notice-service8089notice_dbNotices, document distribution, audience targeting
notification-service8090notification_dbSMS (Africa's Talking), email, delivery webhooks
file-service8091file_dbMinIO uploads, presigned URLs, receipt PDF generation
report-service8092report_dbDirector dashboards, aggregated read models

Payment claim flow (cross-service)

Parent Portal → api-gateway → fee-service (create claim) fee-service → RabbitMQ: PaymentClaimSubmitted notification-service → SMS to bursar Bursar Admin → fee-service (approve) fee-service → DB: payment + allocation (transaction) fee-service → RabbitMQ: PaymentReceived ├→ file-service: generate receipt PDF ├→ notice-service: add to parent document library ├→ notification-service: SMS parent └→ finance-service: post journal entry

Gateway route map

/api/v1/auth/**           → auth-service
/api/v1/org/**            → organization-service
/api/v1/students/**       → student-service
/api/v1/fees/**           → fee-service
/api/v1/portal/**         → fee-service + notice-service (BFF optional in report-service)
/api/v1/admin/**          → respective admin routes per service
/api/v1/files/**          → file-service
/api/v1/notifications/**  → notification-service (internal + webhooks)

Communication patterns

  • Synchronous: REST via gateway for reads/writes that need immediate response
  • Asynchronous: RabbitMQ topic exchange school.events for side effects (notifications, PDF, ledger)
  • Saga: Payment approval uses local DB transaction + outbox pattern; consumers idempotent
  • No shared DB: Each service owns its schema; cross-service IDs are UUIDs only

Security

  • JWT access token (15 min) + refresh token (7 days) from auth-service
  • Roles: SYSTEM_ADMIN, DIRECTOR, BURSAR, TEACHER, RECEPTION, PARENT, HEALTH_RECORDS_VIEWER
  • Health Records Access group — explicit staff list; only members + director view health-service data
  • Campus-scoped roles via campus_id claim in JWT
  • Parent endpoints enforce guardian–student link in fee-service
  • All payment state changes append to immutable audit log

Docker deployment

Phase 1 (Core only):
  - gateway + auth, organization, student, file, notification (6 services)
  - postgres×6, rabbitmq, redis, minio, react-web

Full product (modules 1–12):
  - gateway, 14 services, postgres×14

With extended modules 13–22 (when sold):
  - up to 24 additional services — see extended roadmap

Extended roadmap services (13–22)

ServiceModule
transport-service13 Transport
boarding-service14 Boarding & hostel
scholarship-service15 Scholarships
welfare-service16 Discipline & welfare
timetable-service17 Timetable
chat-service18 Official chat
calendar-service19 Events & calendar
hr-service20 HR & payroll
elearning-service21 E-learning
library-service22 Library

Extended modules roadmap · Core Foundation plan

Technology versions (target)

  • Java 21, Spring Boot 3.3+, Spring Cloud Gateway
  • React 18 + TypeScript, Vite
  • PostgreSQL 16
  • RabbitMQ 3.13
  • MinIO latest compatible