Problem & Constraints
Community rhythm-game tournaments typically break down across manually edited spreadsheets, scattered Discord threads, and error-prone broadcast scoreboards. I joined a team to build corpo-ch to act as a single relational source of truth connecting player signups, qualifier score ingestion, organizer spreadsheets, Discord roles, and live match overlays.
Architecture & Tradeoffs
[ Players / Staff ] ---> [ Django Web App + Discord OAuth2 ] ---> [ MySQL ]
| ^
Enqueue Async Jobs |
v |
[ Celery Worker Pool ] <--------------------+
/ \
v v
[ Google Sheets API ] [ Discord Bot / Live Overlays ]
- Relational Core (Django + MySQL): Normalized player profiles, tournament divisions, qualifier submissions, and live match states in MySQL so standings, seeding, and match history remain consistent under concurrent updates.
- Asynchronous Syncing via Celery: External Google Sheets API calls and Discord webhook bursts introduce unpredictable latency and strict rate limits. Offloading sheet synchronization and bracket notifications to Celery background workers keeps web requests fast and enables safe, retryable background jobs.
- Unified Discord Identity & Broadcast Overlays: Discord OAuth2 links web sessions directly to server accounts and bot permissions, eliminating manual verification. Dedicated overlay routes expose live match states directly to OBS browser sources so commentators never manually re-type scores mid-match.
Debugging & Reliability Win
- Decoupling External I/O from Request Lifecycles: Moving spreadsheet writes and qualifier syncs out of synchronous Django views prevented request timeouts during peak qualifier deadlines and allowed idempotent task retries when external APIs throttled.
| Pipeline Stage | Architectural Guarantee |
|---|---|
| Authentication | Discord OAuth2 tied directly to player records |
| Spreadsheet Sync | Non-blocking Celery tasks with retry handling |
| Live Overlays | Read-only views backed directly by MySQL match state |