<aside>

This section is part of the 5-hour System Design course by Mukul Raina

SLIDE 43: Section Intro, Data Flow

Section 5: Data Flow

image.png

Section 4 defined the components. This section defines how data moves between them. A system architecture diagram with 45 boxes is meaningless until you can trace a request through it, name every service it touches, and explain whether each hop is synchronous or asynchronous. Data flow is where the architecture comes alive.

In a ride-sharing platform, there are three primary data flows that exercise fundamentally different patterns: the ride request flow (synchronous orchestration under a latency budget), the location update flow (high-throughput streaming writes), and the trip completion flow (synchronous finalization followed by asynchronous fan-out). Understanding these three flows is enough to explain how the entire system works.

What We’ll Cover:

  1. The three primary data flows: ride request, location update, trip completion
  2. The trip state machine: states, transitions, cancellation, and failure
  3. Synchronous vs asynchronous: which operations and why
  4. Event-driven processing and dead letter queues
  5. Data ownership across service boundaries
  6. Race conditions in real-time matching

This section connects backward to the architecture from Section 4 and forward to every deep-dive section that follows. When we discuss geospatial design in Section 6, matching in Section 7, or database selection in Section 8, we will reference the flows defined here.

<aside>

Mukul Raina | youtube.com/@mukulraina | slides.mukulraina.com | LinkedIn

</aside>


SLIDE 44: The Three Primary Data Flows

Three Flows, Three Patterns

Every operation in the system belongs to one of three primary data flows. Each flow exercises a different architectural pattern, has a different latency profile, and stresses different components.