System Design Prompt
Design the video upload subsystem for a YouTube-like product that supports large video files.
Core user flow
-
User selects a large video file (hundreds of MB to tens of GB).
-
Upload should be
reliable
(resume after network drops).
-
After upload, the platform processes the video (e.g., transcode) and eventually makes it playable.
Requirements
-
Support
resumable uploads
and unstable mobile networks.
-
Efficiently handle large files (chunking, retries, integrity checks).
-
Provide upload status to clients (progress, failure reasons).
-
Ensure uploaded content is durable and not lost.
-
Basic security: authenticate users, authorize uploads, prevent misuse.
Scale assumptions (state your own if needed)
-
Millions of users
-
Spiky traffic (new releases)
-
Global uploads
Deliverables
-
APIs, data model, and high-level architecture
-
Storage strategy for raw uploads and processed outputs
-
Processing pipeline (transcoding, thumbnails)
-
Failure handling, idempotency, and observability
-
Key trade-offs