Designing High Scale Live Streaming Architecture 🏈


Hello Reader,

A common system design interview question for Media and Entertainment domain is designing high scale live streaming applications. We just had Super Bowl in USA, which is the highest watched event in the USA (126 Million). How do high-scale sporting events like Super Bowl, Olympics, Soccer finals, and Cricket matches get streamed to millions of viewers? And how are personalized dynamic advertisements shown to you? Here's how:

  • Live cameras in the stadium capture the action
  • AWS Elemental MediaLive takes the raw video input from the cameras into AWS, and encodes it in real-time, compressing the content into smaller, high-quality streams suitable for broadcast and internet delivery. MediaLive also translates the streams into different languages!
  • MediaPackage takes the video input and packages it into multiple streaming formats, enabling content delivery to a wide range of playback devices such as connected TVs, mobile phones, computers, tablets, and game consoles
  • These various streaming format output is fed to CloudFront. Different devices consume the stream from this CloudFront. You can enable AuthN/Z with CloudFront from the streaming app.
  • Elemental MediaPackage can also save the video in S3 bucket for VOD
  • All these services can scale automatically to support millions of viewers worldwide!

How about ads? This is how dynamic ad insertion works:

  1. CloudFront requests manifest (video clip with ads) with viewer information which is used for ad personalization
  2. MediaTailor gets manifest i.e. video clip with ad markers (which time frame to insert the ads). At this point, NO ads have been inserted
  3. MediaTailor requests personalized ads based on viewer information from ADS (Ad Decision Server). ADS is a third-party software, that can run on EC2
  4. ADS running on EC2 return ad(s) to the MediaTailor. Note that, ads returned for one viewer will vary from another based on the information gathered by the streaming platform, that was passed to MediaTailor
  5. Mediatailor inserts these ad(s) into the manifest at the ad markers
  6. MediaTailor returns this video clip with ads or manifest with ads to the CloudFront. The clip with ads is shown to the viewers consuming from the CloudFront

If this comes in your system design interview, be sure to knock it out of the park!

If you have found this newsletter helpful, and want to support me πŸ™:

Checkout my bestselling courses on AWS, System Design, Kubernetes, DevOps, and more: Max discounted links​

AWS SA Bootcamp with Live Classes, Mock Interviews, Hands-On, Resume Improvement and more: https://www.sabootcamp.com/​

Keep learning and keep rocking πŸš€,

Raj

Fast Track To Cloud

Free Cloud Interview Guide to crush your next interview. Plus, real-world answers for cloud interviews, and system design from a top Solutions Architect at AWS.

Read more from Fast Track To Cloud

Hello Reader, In the previous newsletter edition, we took a look at top Gen AI tools, and how can you benefit from the trend. The matter of the fast is, even in general SA interviews, you have to expect Gen AI questions. This is similar to how you expect fundamental containerization and DevOps questions. Gen AI is becoming quite popular, and this is no exception. In today's edition, let's go over AWS Gen AI landsacape, that I am following: The image illustrates the AWS Generative AI (Gen AI)...

Hello Reader, Agentic AI is the new buzzword. Every YouTube video, LinkedIn article, and blog is about Agentic AI. In today's edition, we will go over what is Agentic AI, and why is it becoming so popular. To understand this, we have to see the evolution of LLMs, let's find out: In the beginning, there was a single LLM, and we were doing prompting. This was significant first step, but it had the following challenges: Static, pre-trained information Not able to integrate project-specific data...

Hello Reader, The landscape of generative AI (Gen AI) consumer applications is evolving rapidly, with new players emerging and established ones innovating at an unprecedented pace. In today's newsletter, we will take a look at the top Gen AI apps and, more importantly, how YOU can use this for your career growth and get more money. Generative AI Consumer Apps: The Top Performers ChatGPT's Resurgence: After an initial plateau, ChatGPT has surged to 400 million weekly active users, driven by...