All problems

Multiplayer Game Backend

Hold a 50ms tick budget through launch day.

hard~22 min Pro Simulator · +140 ptsTheory +45 pts
The build

Hold a ~50ms tick budget through launch day while instances die and a zone link severs.

Every player action must round-trip inside the tick budget, so the sim fleet and its stores live or die by headroom. Session state sits in a KV; matchmaking and profile reads must come from a cache — a store round-trip per tick blows the budget, and a lost sim instance must hand its matches to survivors.

Components in play

  • Realtime gatewayHolds player connections and routes actions to the sim fleet.
  • Game-sim fleetRuns the authoritative tick loop for live matches.
  • Sim-write fan-outSplits sim-fleet output between the session KV write path and the match/profile cache reads so neither branch starves.
  • Match/profile cacheServes matchmaking and profile reads without touching the store.
  • Session-state KVSnapshots of live sessions so a match survives its instance.

Graded on these SLOs

  • ≥ 99.00%Actions land
  • ≤ 50 msTick-budget p99
  • ≥ 12k rpsSustain the actions
  • ≤ 90%Fleet headroom
  • ≤ 10Lean fleet
Base 12,000 rps46s run 4 scripted failures

The brief

Design the backend behind a live multiplayer game: players connect, take actions, and every action has to round-trip inside a tight tick budget for the game to feel real. Session state has to survive a crashed instance, matchmaking and profile reads can't touch the hot path, and a launch-day login stampede can't be allowed to blow the budget.

Functional

  • Run the authoritative simulation for live matches
  • Persist session state so a match survives its instance
  • Serve matchmaking and profile lookups

Non-functional

  • Action-to-fill latency stays inside the tick budget (~50ms p99)
  • A crashed sim instance doesn't drop the matches it was running
  • Survive a launch-day login stampede without degrading the tick

Warm-up: design decisions

Optional theory to prime the calls a senior engineer would make before you build.

Pro

Solving is a Pro feature

Unlock the on-canvas AI design coach, per-run design reviews, the chaos simulator and all 12 problems for $15/month.

  • AI design coach on your canvas — pins failure points & over-engineering
  • Honest AI design review on every run
  • All 12 problems + unlimited chaos simulator
  • Points, levels & leaderboard
Get started