Friday, December 4, 2015

Facebook Engineering: Building a Live Video Broadcast Capability

The Facebook Engineering team is building the ability for people to share live video on Facebook, potentially to very large numbers of viewers.

In this blog post, engineers described "the thundering herd" problem - public figures with millions of followers on Facebook may suddenly start a live broadcast. Facebook needs to be able to handle the potential of more than a million people watching the broadcast at the same time, as happened recently with a live stream from Vin Diesel.

Facebook's approach is to deploy a network of edge caches around the globe. A live video is split into three-second HLS segments, which are sequentially requested by the video player displaying the broadcast. The segment request is handled by one of the HTTP proxies in an edge data center, which then checks with an edge cache and the origin cache. Facebook is aiming to take the latency "down to a few seconds."

A trial of these capabilities is starting with a small percentage of people in the U.S. on iPhones.

https://code.facebook.com/posts/1653074404941839/under-the-hood-broadcasting-live-video-to-millions/