Designing TikTok: A Scalable Backend Distributed System

TLDRThis video discusses the design of TikTok's backend distributed system that supports uploads and downloads. The system handles one billion users, one billion video views per day, and 10 billion videos uploaded per year. The video storage uses Amazon S3 for scalability and replicates data for better availability. The video metadata is stored separately using a key-value storage solution. The backend system also focuses on maximizing time spent in the app as a success metric. Additionally, the video storage is tiered to optimize cost and performance.

Key insights

📺TikTok's backend distributed system handles one billion users, one billion video views per day, and 10 billion videos uploaded per year.

💾The video storage uses Amazon S3 for scalability and replication to ensure better availability.

🔑The video metadata is stored separately using a key-value storage solution.

⏱️Maximizing time spent in the app is a key success metric for TikTok.

💡The video storage is tiered to optimize cost and performance, with older videos moved to slower offline storage.

Q&A

What are the key metrics for success in TikTok's backend system?

The key metrics for success in TikTok's backend system include maximizing time spent in the app and ensuring high availability of videos and metadata.

How does TikTok handle the large amount of video uploads and views?

TikTok handles the large amount of video uploads and views through scalable backend distributed systems, tiered video storage, and data replication for better availability.

What storage solutions does TikTok use for videos and metadata?

TikTok uses Amazon S3 for video storage and a key-value storage solution for video metadata.

How does TikTok optimize cost and performance in its video storage?

TikTok optimizes cost and performance in its video storage by tiering the data and moving older videos to slower offline storage.

What challenges does TikTok face in designing its backend distributed system?

TikTok faces challenges in handling the massive scale of its user base and video content, ensuring high availability, and maintaining optimal cost and performance.

Timestamped Summary

00:01This video discusses the design of TikTok's backend distributed system that supports uploads and downloads.

02:00The backend system handles one billion users, one billion video views per day, and 10 billion videos uploaded per year.

03:50The video storage uses Amazon S3 for scalability and replicates data for better availability.

05:45The video metadata is stored separately using a key-value storage solution.

06:01Maximizing time spent in the app is a key success metric for TikTok.

09:32TikTok's backend system handles approximately 300 video uploads per second and 10,000 video views per second.

13:29The video storage is tiered to optimize cost and performance, with older videos moved to slower offline storage.

19:44TikTok's backend system consists of multiple services, including video storage, video metadata storage, and application services.