ArchitectureMajor Upgrades & Infrastructure
Architecture9 min readInfrastructure
Major Upgrades & Infrastructure
This document summarizes the major architectural transformations, resilience engineering, cloud deployments, multi-tier database failovers, 24/7 infinite crawle...
Mission Control — Major Upgrades, Architecture & Infrastructure Reference
This document summarizes the major architectural transformations, resilience engineering, cloud deployments, multi-tier database failovers, 24/7 infinite crawler auto-revive engines, and backup systems implemented in the Mission Control Distributed Ecosystem.
1. Executive System Architecture
SYSTEM ARCHITECTURE DIAGRAMMERMAID SVG ENGINEGenerating visual flowchart...
2. The 12 Major Architectural Upgrades
🚀 1. Quad-Storefront Ingestion Engine
- Before: Single-store indexing (Steam only).
- Now: Integrated live autonomous harvesters across Steam, Epic Games Store, GOG Galaxy (DRM-Free), and Xbox & PC Game Pass.
- Impact: Canonical game catalog surged from
2,066to13,500+production titles and continues to grow 24/7.
🛡️ 2. Multi-Tier Database Architecture & Built-in Backup Replica
- Before: Single Supabase cloud dependency. If Supabase went down or paused, the application would crash.
- Now: Built a resilient 3-Tier Multi-Database Engine in
db.py:- Tier 1 (Primary Cloud): Supabase PostgreSQL (
db.vekqkwwzzamwhitjodld.supabase.co:5432). - Tier 2 (Secondary Standby Cloud): Hot standby via
FALLBACK_DATABASE_URL(e.g. Neon Serverless Postgres). - Tier 3 (Local SQLite Backup Replica): Embedded persistent replica (
data/catalog_fallback.db). Auto-syncs on every write and seamlessly serves read/search queries offline with zero network dependency. - Redis Cache: Upstash REST client for sub-millisecond in-memory caching.
- Tier 1 (Primary Cloud): Supabase PostgreSQL (
🔄 3. 24/7 Infinite Ingestion Auto-Start & Supervisor Watchdog
- Before: Crawler stopped when server processes were reset or required manual terminal commands.
- Now:
- Embedded Lifespan Auto-Boot:
server.pyautomatically boots all 6 crawler threads on application startup (start_infinite_crawler_in_background()). - 5-Second Supervisor Watchdog:
crawler_service.pycontinuously monitors all 6 worker threads (Steam, GOG, Epic, Xbox, AI Classifier, Healer). If any thread crashes due to network timeouts or rate limits, the supervisor automatically catches the exception and revives the thread within 5 seconds.
- Embedded Lifespan Auto-Boot:
🏪 4. Dedicated launchers TEXT[] Column & Exclusivity Detection
- Before: Store availability was buried in raw JSON metadata.
- Now: Added a first-class
launchers TEXT[]array column to PostgreSQL:- Epic Exclusives: Alan Wake 2, Fortnite $\rightarrow$
['Epic Games'] - Xbox / PC Game Pass: Halo Infinite, Forza Horizon 5, Avowed $\rightarrow$
['Steam', 'Xbox', 'PC Game Pass'] - Multi-Store PC Releases: Cyberpunk 2077, The Witcher 3, Control $\rightarrow$
['Steam', 'Epic Games', 'GOG Galaxy']
- Epic Exclusives: Alan Wake 2, Fortnite $\rightarrow$
⚡ 5. Non-Blocking Sub-100ms Search Optimization
- Before: Live searches ran synchronous LLM calls (Gemini/OpenRouter), causing 5–15 second latency and timeouts.
- Now: Decoupled synchronous LLM calls from search handlers. Live store search returns in < 100ms using instant store tags, while deep AI metadata enrichment runs in background worker threads.
⚖️ 6. Multi-Pool Load Balancer Gateway (:8800)
- Before: Direct, single-process connections susceptible to traffic overload.
- Now: Built
load_balancer.pywith round-robin balancing across 5 microservice pools, sub-1.5s health probing, automatic upstream failover, and strict isolation of crawler workloads from user traffic.
📅 7. Autonomous Release Date Healer
- File:
heal_release_dates.py - Now: Continuously resolves
NULLrelease dates by querying official Steam Store APIs and RAWG. Over2,690+dates healed.
🖼️ 8. HD Portrait Box Art vs. Landscape Hero Banners
- Before: Square or landscape thumbnails were used for vertical library grid cards.
- Now: Vertical High-Definition Portrait Box Art (
library_600x900_2x.jpg) is separated from wide Landscape Hero Banners (library_hero.jpg), with automatic fallback to high-resolution photorealistic artwork.
🐧 9. Full Linux & Steam Deck Support
- Now: Default platform arrays across all database rows, models, and harvesters include
["Windows", "Linux"](and["Windows", "Linux", "Xbox"]for cross-play).
🛡️ 10. Autonomous Server Watchdog & Self-Healing Agent
- File:
server_watchdog_agent.py - Now: Standalone monitoring daemon checking all cluster ports with
/api/agent/diagnosticsfor automated health telemetry and self-healing restarts.
🌐 11. UptimeRobot Keep-Alive Integration (Zero Sleep / Zero Pause)
- Endpoints:
GET /andGET /healthonhttps://mission-control-server-okj7.onrender.com - Now: Handles both
GETandHEADprobes. Every 5-minute ping prevents Render free-tier containers from going to sleep while actively executingSELECT 1SQL queries on Supabase to prevent the 7-day inactivity pause.
🔍 12. Root Domain Welcome & Discovery
- Now: Visiting
https://mission-control-server-okj7.onrender.com/displays the active API routing directory and online status instead of returning404 Not Found.
⚡ 13. Real-Time Node Presence & Incremental Library Sync Engine
- Files:
Gaming/backend/handlers/game_handler.py&Gaming/distributed_node/node_service.py - Before: Opening the Desktop App left node status as
offlineand version mismatched as1.0.0in Supabase unless manually registering via terminal scripts. Game additions or uninstallations required manual button scans. - Now:
- Autonomous Node Auto-Spawn & Version Alignment: Launching the desktop application automatically boots the
LibraryNodeServicedaemon, instantly registering the node in Supabase (library_nodes) with statusonline, dynamic app version alignment (v3.2.8loaded directly fromversion.json), and transmitting real-time 15s heartbeats with accurate physical disk metrics. - Real-Time Differential Sync (Insert / Update / Delete):
LibraryWatcherdetects local file system and registry changes. When games are installed or deleted:- INSERT / UPDATE: Upserts new game titles, paths, executables, icons, and size metrics into Supabase (
gamestable). - DELETE: Executes automatic deletion SQL queries to prune uninstalled games from Supabase in real time without orphaned records.
- INSERT / UPDATE: Upserts new game titles, paths, executables, icons, and size metrics into Supabase (
- Autonomous Node Auto-Spawn & Version Alignment: Launching the desktop application automatically boots the
🛡️ 14. Zero-NULL Data Ingestion & Multi-CDN Image Fallbacks
- File:
Gaming/backend/system/db_manager.py - Before: Games scanned from local drives or obscure storefronts lacked explicit
sourceandlocal_bannermetadata, resulting inNULLvalues in Supabase. - Now:
- Source Sanitization: Automatically infers and normalizes missing store sources from the platform identifier (e.g.
steam,epic,gog,xbox,local) instead of writingNULL. - Multi-CDN Banner Cascade: Automatically resolves missing hero banners from the Steam CDN (
https://cdn.akamai.steamstatic.com/steam/apps/<id>/header.jpg) or curated game artwork fallbacks. - Zero-NULL Guarantee: All records in
gamesandcanonical_gamesmaintain complete relational integrity across all columns.
- Source Sanitization: Automatically infers and normalizes missing store sources from the platform identifier (e.g.
📂 15. Automated Store Hint Classification for Node Scan Paths
- Files:
Gaming/distributed_server/db.py&Gaming/distributed_node/node_service.py - Before: Scanning custom or launcher paths inserted
NULLinto thestore_hintcolumn ofnode_scan_paths. - Now:
- Dynamic Path Detection: Automatically detects all active library drives, Steam libraryfolders, Epic manifests, and custom directories on startup.
- Intelligent Store Classification: Automatically maps filesystem paths to precise store hints (
steam,epic,gog,ea,ubisoft,xbox,battlenet,riot,local).
3. Microservice Port Matrix
| Service | Port | Description |
|---|---|---|
| Load Balancer Gateway | :8800 | Unified reverse proxy with instant failover and pool routing. |
| Catalog Discovery Service | :8811 / :8812 | Sub-100ms search, catalog discovery, and game seeding pool. |
| User Library & Node Sync | :8821 / :8822 | Local hardware node detection and storage metrics pool. |
| AI Metadata Enricher | :8831 | Dedicated LLM feature & summary generator. |
| Multi-Launcher Store Healer | :8841 | Cross-store exclusivity & multi-launcher array sync. |
| Infinite Crawler & AI Harvester | :8851 | 24/7 6-thread quad-store ingestion & supervisor auto-revive daemon. |
4. Production Database Metrics
| Metric | Before | Current Live Production |
|---|---|---|
| Total Ingested Games | 2,066 | 13,500+ Titles |
| AI Classified Titles | 1,497 | 10,500+ (77.8%) |
| Integrated Storefronts | Steam | Steam, Epic Games, GOG Galaxy, Xbox / PC Game Pass |
| Platform Compatibility | Windows | Windows, Linux, Steam Deck, Xbox |
| Search Response Latency | ~5,000ms | < 100ms |
| Crawler Self-Healing | Manual Restart Required | Embedded Server Lifespan + 5-Second Supervisor Watchdog |
| Database Resilience | Single Supabase Host | 3-Tier Engine (Supabase + Cloud Fallback + Local SQLite Replica) |
| High-Availability Uptime | Single Process | 5-Tier Microservices + Load Balancer + UptimeRobot Keep-Alive |