Skip to main content
Intermediatehow it works

How do you approach a data pipeline system design question?

Source: Google SRE book: data processing pipelines

Quick answer

I clarify first: who consumes the data, how fresh it must be, the volume and peak, whether the source can replay, and the SLA. Then I estimate rates and storage.

I clarify first: who consumes the data, how fresh it must be, the volume and peak, whether the source can replay, and the SLA. Then I estimate rates and storage. I sketch ingest, storage layers, processing and serving, and name the tools only after the shape is clear. Then failures: retries, duplicates, late data, bad records. Then quality checks, monitoring and alerting, and finally cost and the trade-offs I made, including what I would do differently at ten times the volume.

Animated explanation
  1. 1Clarifyconsumers, latency, volume, SLA
  2. 2Estimateevents/s, GB/day
  3. 3Sketchingest, store, process, serve
  4. 4Failuresretry, duplicates, late data
  5. 5Qualitychecks, reconciliation
  6. 6Operatemonitoring, cost, trade-offs
The same six steps work for batch and streaming designs.

Key points

  • clarify requirements
  • estimate
  • data flow before tools
  • failure handling
  • trade-offs

Common mistakes

  • Naming Kafka and Spark in the first minute, before knowing the latency need.

References

Discussion