Case Studies
A photo feed with a media pipeline in front of it — presigned direct uploads, async processing, and CDN-fronted delivery.
Designing a photo/video-sharing feed — the fan-out problem is structurally the same shape as Twitter's feed, but this design has a media pipeline in front of it: uploads have to land in durable object storage, get processed asynchronously, and be served globally through a CDN, none of which a text-only feed needs to think about.
A user uploads a photo or short video with a caption. People who follow them see it in their feed, most recent first.
What this lesson covers
Clients upload straight to object storage with a presigned URL; async jobs make thumbnails, transcode video, and run moderation before the post flips to published and fans out to followers' feeds. Reads hit a CDN with request coalescing, never origin storage directly.
- An upload is a roll of film at the lab: the raw file lands durably at once, but nobody sees it until processing is finished.
- Two hard problems stacked: a media pipeline (thumbnails, transcoding, moderation) in front of a fan-out feed problem.
- Reuse the news-feed hybrid fan-out rather than re-deriving it; the new work is the upload and delivery path around it.
- Presigned direct-to-storage uploads and asynchronous processing are the senior bar; bytes should not transit app servers.
- Staff answers explain what bounds origin load when a post goes viral across many edge locations, not just that a CDN exists.
Included in Plus and Pro
Continue reading “Instagram”
The full lesson works the design through end to end — diagrams, trade-offs, and what interviewers expect at each level. About 19 minutes.
- Understanding the Problem
- Functional Requirements
- Non-Functional Requirements
- Capacity Estimation
- Core Entities
- API Interface
- High-Level Design
- Trade-offs
- Final Design
- Operations & Observability
- Level Expectations
- Follow-Up Questions
- Try It Yourself