System Design Atlas

Live sports interaction for large audiences

06 / 10Worked example

The overall architecture

Chat scales independently of votes. What conditions ensure the result?

Moderation and fanout have different load drivers.

Starting point The final tally binds a complete watermark.

Assumptions for the example case

A fictional audience poll on the best play. Each account can cast at most one immutable vote per poll. Chat has a separate moderation path. All quantities, thresholds and operational objectives of this design are illustrative assumptions.

Two processing paths

Two processing paths

BrowsersVote + chat
Interaction APIAccount + Deadline
Vote partitionVotes by Poll + Account
Aggregation workerWatermark
Result projectionIntermediate + Final
Chat APIChat acceptance
Chat storeVersions
Moderation workerRelease / Removal
FanoutworkerChannels
Live transport serviceExternal
Browser → Interaction APIVote
Interaction API → Vote partitionAccount + poll atomically
Vote partition → Aggregation workerCommitted votes
Aggregation worker → Result projectionTally + watermark
Browser → Chat APIChat contribution
Chat API → Chat storeC-51
Chat store → Moderation workerSubmitted posts
Moderation worker → Fanoutworkerrelease version
Fanoutworker → Live Transportation ServiceChannel Event
Live Transportation Service → BrowserLive Update

Vote acceptance and aggregation remain separate from moderated chat and fanout.

API/vote partition/aggregation/result; chat/moderation/fanout; external transport service.

Responsibilities within the application

Modules of the Interaction Application

Vote acceptanceChecks account, deadline and uniqueness
TallyingTallies votes with a watermark
Chat moderationReviews Contribution Versions
Live deliverydistributed released events
Abstimmungsannahme → ErgebnisbildungCommitted vote
Chatmoderation → Live-AuslieferungReleased version
Ergebnisbildung → Live-AuslieferungConfirmed results

Acceptance, outcome, moderation and delivery have separate responsibilities.

Application modules: Vote acceptance checks account, deadline and uniqueness. Tallying produces traceable totals from accepted votes. Chat moderation reviews posts for publication. Live delivery distributes approved events and current results. The overall architecture maps these responsibilities to runtime processes and storage.

Runtime components and authoritative data

Runtime boundary
Browser → interaction API → vote partition by poll and account hash. An aggregation worker reads committed votes and writes a result projection with a watermark. Chat API → chat store → moderation worker; approved versions → fanout worker → external live transport service → browser. Vote acceptance remains separate from the chat path.
Module responsibilities
Vote acceptance checks account, deadline and uniqueness. Tallying produces traceable totals from accepted votes. Chat moderation reviews posts for publication. Live delivery distributes approved events and current results.

Chat scales independently of voting.

Chat scales independently of voting.

Separate workers and datastores implement different rules.

Moderation and fanout have different load drivers.

Vote records and chat versions. Result projections and delivered feeds can be rebuilt from the authoritative data.

Alternative considered
A shared bottleneck delays vote acceptance.
Trade-off
More operational building blocks are needed.
Reassess
Small events could use fewer processes.

Try it yourself

Identify authoritative and derived data.

A hint for your attempt

Moderation and fanout have different load drivers.

Compare with a possible solution
Authoritative
Votes and chat versions.
Derived
Result projections and delivered feeds; rebuild these from authoritative data.

Apply to your project

What is the equivalent of “Chat Scales Regardless of Votes.” in your own project?

Step 7: An account has exactly one winner. What conditions ensure the result?