Amazon Web Services (AWS) offers its customers several methods designed to cost-effectively deliver on-demand video content to a global audience. These methods help enable you to dynamically scale any combination of video processing, delivery, and storage services on the AWS Cloud.  

This webpage provides best practices and guidance to consider when implementing a video-on-demand workflow on the AWS Cloud, and introduces an AWS solution that automatically provisions the services necessary to build a scalable, distributed architecture that ingests, stores, processes, and delivers video content.

The following sections assume basic knowledge of architecting on the AWS Cloud, video-on-demand workflows, video encoding, and video packaging.

When streaming on-demand video in the cloud, there are some universal video-streaming principles that will help you build highly scalable, performant, and resilient on-demand streaming video solutions. Before you implement a streaming solution, determine the requirements for your use case. Consider your sources, encoding and playout formats, as well as the devices you want to target. Then, choose a solution that meets those requirements. Also, weigh the entire cost of the solution against the desired video quality and overall flexibility, scalability, and redundancy. Keeping these general principles in mind, consider the following best practices for streaming video-on-demand on the AWS Cloud:

  • To provide the best experience for all viewers, utilize HTTP-based adaptive bit rate (ABR) formats to let each device continually negotiate the highest quality bit-rate stream available. ABR formats automatically adjust the quality of the delivered content to match the bandwidth available to each client device. ABR-based delivery greatly reduces buffering, provides a fast start time, and provides an optimal viewing experience for a viewer's available bandwidth.
  • Choose a streaming solution that complements your company’s existing processes and skill sets to ensure that you can manage and modify your solution to meet future requirements. This will streamline your video-on-demand workflow and reduce operational complexity for developers and operators.
  • Clearly define an end-to-end workflow with a specific and well-understood design for redundancy and failover. Ensure transcoding, packaging, and origination software and settings are optimized for troubleshooting and management at scale.

AWS offers a solution that ingests metadata files and source videos, processes the videos for playback on a wide range of devices, and stores the transcoded media files for on-demand delivery to end users through Amazon CloudFront. The diagram below presents the video-on-demand architecture you can deploy in minutes using the solution's implementation guide and accompanying AWS CloudFormation template.

  1. This solution uses AWS Lambda to trigger AWS Step Functions ingest and publishing workflows.
  2. A step function ingests a metadata file or a source video. A second step function submits encoding jobs to Amazon Elastic Transcoder, which converts the source video files into formats that will play on devices. After the video is encoded, a third step function validates the output and publishes the video.
  3. Source and destination media files are stored in Amazon Simple Storage Service (Amazon S3) and file metadata is stored in Amazon DynamoDB. If enabled, source files are tagged to allow the files to be moved to Amazon Glacier.
  4. Amazon CloudFront delivers the on-demand video to end users.
  5. Amazon CloudWatch monitors log files and sends Amazon Simple Notification Service (Amazon SNS) notifications for encoding, publishing, and errors.
Deploy Solution
Implementation Guide

What you'll accomplish:

Deploy Video on Demand on AWS using AWS CloudFormation. The AWS CloudFormation template will automatically launch and configure the components necessary to ingest, store, process, and deliver video on demand.

Automatically transcode into multiple resolutions and formats with the solution's seven custom transcoding presets. You can also create your own custom presets with Amazon Elastic Transcoder.

What you'll need before starting:

An AWS account: You will need an AWS account to begin provisioning resources. Sign up for AWS.

Skill level: This solution is intended for IT infrastructure architects, administrators, and DevOps professionals who have experience with video processing and delivery, and practical experience architecting on the AWS Cloud.

Q: What source video formats does the Video on Demand on AWS solution support?

This solution can encode MP4, MPG, M4V, and MOV files.

Q: What output formats does this solution create?

This solution can encode your source videos into HTTP Live Streaming (HLS), standalone MP4, and Dynamic Adaptive Streaming over HTTP (DASH). You can choose from two workflows: one that uses metadata files to apply encoding settings on a video-by-video basis, or one that encodes all videos in the same formats.

Q: What resolutions does this solution output?

This solution includes seven custom transcoding presets for popular output formats. The presets cover the full spectrum of end-user requirements from 1080p down to 234p. You can also create your own custom presets based on an existing preset.

Q: Can I customize and extend this solution for my specific needs?

Yes. This solution leverages AWS Step Functions, which breaks the workflow into individual steps that each perform a discrete function, making it easier to customize or extend the architecture for your specific video-on-demand needs. For example, you can modify or replace the encoding steps to produce different content sets. You can also add steps to extend support for more complex workflows, including image processing for poster artwork or adding additional custom data to the metadata file that will then be stored in Amazon DynamoDB.

Q: Can I deploy this solution in any AWS Region?

This solution uses AWS Step Functions, Amazon Elastic Transcoder, and AWS Lambda. Therefore, you must deploy this solution in an AWS Region that supports these services. For more information, see AWS service availability by region.

Tell us what you think