<img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=1455318828112554&amp;ev=PageView&amp;noscript=1">

Live Streaming Hardware

How BoxCast Encodes, Ingests, Transcodes, and Delivers Live Video Streaming at Scale

BoxCast is a complete, easy-to-use live video streaming solution for organizations. Our customers vary wildly in size from small churches to pro sports teams and professional broadcasters. It is common for us to observe a single broadcast spike in viewership from a few dozen to tens of thousands of concurrent viewers very rapidly.

All the while, hundreds of other broadcasts are being live streamed around the globe. And our system automatically responds day or night to handle the load without blinking an eye.

BoxCast was built by an engineering team who focused on automation. In fact, BoxCast holds patents for automated streaming. Prior to founding BoxCast, our team built mission-critical automation systems for aviation and other industries with no margin for error. Taking this mindset, we have spent years engineering the most advanced video cloud infrastructure in the world.

From Your Camera Through Our Cloud

While you might recognize BoxCast from our "clear box" portable hardware encoder, the BoxCaster, our complete platform lives primarily in the Amazon Web Services (AWS) Cloud. To simplify the view of our cloud infrastructure, we'll discuss four major components: video encoding, video ingest and transcoding, video storage, and video delivery.

BoxCast is built around the concept of broadcasts, which are typically scheduled in advance, allowing us to predict and automate the provisioning of cloud resources in advance of events.

We long ago recognized that the network is almost always the single weakest link in any video streaming effort. Because of that, we offer cloud transcoding for every broadcast, which means your encoder only needs to send a single video stream (at the highest quality it can) and our cloud will split it into multiple variations for viewer compatibility.

The encoding happens at your site, normally using a BoxCaster encoder or Broadcaster app, but sometimes also using a third party RTMP-compatible encoder such as Wirecast or OBS. Each encoder is responsible for handling a single broadcast - as such, it scales naturally by deploying more encoders.

baby encoding.png 

Ingest, Transcoding, and Delivery are all important aspects of the BoxCast cloud that must be built for scale, because thousands of encoders are often competing for resources to serve their viewers. As such, the BoxCast Platform has adopted multiple horizontal scaling methodologies, with our backbone based primarily in AWS.

Scaling Video Ingest and Transcoding

The encoder compresses video and sends it up to an ingest point, often at a very high bitrate and up to 60 frames per second. During peak broadcast times (Friday night football, Sunday morning worship services, etc.), the BoxCast cloud must scale to ingest hundreds or even thousands of simultaneous inbound streams. In a dedicated server environment, a provider would need to make sure there is always enough resources to handle the absolute peak - but with cloud scaling, BoxCast is able to dynamically provision resources when necessary and then free them up during idle periods.

Note: The point of "ingest" is the link between the encoder and our cloud. To overcome limitations of other ingest protocols such as RTMP, we developed BoxCast Flow - this is the language our encoders talk to our ingest servers.

We scale our cloud ingest and transcoding with a custom architecture and resource manager that leverages mixed compute instance types with significant CPU and GPU resources for optimal and efficient video encoding. Moving to GPU (Graphics Processor Unit) cloud encoding was a significant step - we can take advantage of the leaps in efficiencies used by video gaming to handle video processing much more effectively than a general purpose CPU.

In years past, we might have provisioned a single cloud server per broadcast. Now, with much more sophisticated hardware and software, multiple transcode tasks can live on a single virtual instance without impacting performance or compromising security. To this end, BoxCast has adopted Docker containerization across the platform, both for microservices that support various platform features such as analytics or notifications, but also for video transcoding tasks. The individual containers provide an ability to quickly react to the need to scale.

toy story .png

Our automated cluster manager understands the global view of all broadcasts and is constantly orchestrating and reprovisioning compute resources to handle tasks as the need arises. The cluster manager is aware of each stream's parameters to ensure it provisions a large enough chunk of compute resources. It is not uncommon to scale from a small handful of servers in a transcode pool up to hundreds of live transcode tasks of varying sizes in a matter of minutes.

blog chart .png

Scaling Video Storage

Video files are absolutely huge. Especially for broadcasts that are several hours long and transcoded into 4 or more bitrate levels. Your phone is probably at capacity right now because of the short clips you filmed - just imagine how much space BoxCast needs!

petabytes grandma .png

BoxCast leverages multiple storage strategies to enable cost-effective and limitless options for keeping your broadcasts available for viewers.

After a video is transcoded, multiple formats for different resolutions and bitrates must be stored. These are placed in long-term durable storage in S3 (AWS's Simple Storage Service) immediately by the transcode tasks. S3 was built to deliver a 99.999999999% durability promise and infinite scale. Data is automatically distributed across a minimum of three physical facilities that are geographically separated within an AWS Region. The BoxCast implementation on top of S3 allows for a near immediate and seamless transition from a live recording to an on-demand experience.

Retention policies are in place and configurable for your account. Some broadcasters prefer to only keep broadcasts in the BoxCast cloud for 30 days, 90 days, or one year max, and then export or delete them. Others want to keep them indefinitely - it's up to you. BoxCast will never run out of storage for your videos.

Scaling Video Delivery

Once BoxCast has encoded, ingested, transcoded and stored all of the video files, we must ensure that viewers can watch them on any device, in any location.

Remember how we said video files are huge? Well, when you have tens of thousands of viewers, your bandwidth to serve them grows very quickly — and a single server even with a tremendous network connectivity cannot handle the load.

GOT viewers .png

BoxCast leverages HTTP Live Streaming (HLS), which was originally pioneered by Apple and is now broadly supported by a multitude of devices including mobile devices, computers, smart TVs, and connected OTT appliances. At the end of the day, a streaming video that utilizes HLS comprises of a series of video files that can be served just like a web page or downloaded file from the internet. This allows us to adopt web scaling strategies that have been perfected for decades and optimized beyond video-specific protocols that often have challenges scaling to large swings in viewership. Our HLS implementation works closely with our video players to choose settings that effectively balance compatibility, scalability, latency, and other viewer experience attributes.

We leverage AWS Cloudfront as a traditional CDN with multiple points of presence globally. The CDN is configured dynamically to support both live streams being transcoded in real time and recorded on-demand videos.

For further scale and experience improvements, BoxCast has partnered with Peer5 to enable a Peer Assist feature for viewership. This emerging technology is built on a P2P network utilizing WebRTC to help distribute video files more efficiently. With Peer Assist enabled, we've been able to measure dramatic user experience improvements in rebuffer percentage for remote areas in places such as South America and Africa, as well as domestically in some cases.

Additionally, when there is concentrated viewership on a single local network (such as enterprise users watching the same town hall or multiple students on campus watching the same lecture stream or basketball game), Peer Assist avoids saturating the site's internet uplink by offering a local CDN point of presence. 

Trust BoxCast

BoxCast achieves scale without sacrifice. The impressive amount of engineering by our team that has led to the current architecture allows us to offer streaming services to you at a quality level and price that no competitor can match.

If you'd like to learn more about working with us, either as a customer, a partner, or as part of our team building the world's most advanced video platform, get in touch today.