Using Celadon in Container to Build Scalable, Cost-Efficient Android Solutions on x86
Target Customers
Cloud Service Providers and Intelligent TV providers seeking to deploy video application streaming services in the cloud.
Introduction
Cloud Service Providers (CSPs) and Intelligent TV providers are experiencing a considerable increase in demand for media services such as live video streaming, cloud gaming, media analytics and more, with each of these markets expected to rapidly be worth billions. Consider the following statistics:
- In 2018, video made up almost 58% of downstream traffic on the internet1. By 2021, video will make up 82% of all IP traffic2.
- Facebook generates 8 billion video views per day3.
- The Video on Demand (VoD) market is expected to grow from USD 38.9 billion in 2019 to USD 87.1 billion by 20244.
Additionally, as more media content is being created, users are increasingly consuming their chosen media through digital formats across a wide number of devices. A 2018 survey found that 85% of internet users in the United States watched online video content on any device5. This behavior only seems to be increasing, with 49% of respondents to a Statista survey stating that they watched more online video content in 2018 compared to the previous year6. Overall, the explosion of client devices capable of supporting digital media - from TVs to laptops to smart phones - along with the sharp increase in internet bandwidth has given consumers more options to access the media they want, when they want, on the most convenient device at that moment.
Provide Customers with High-Quality Media Content with Celadon in Container
These user patterns are increasingly driving providers to make applications device independent. Specifically, applications have now evolved to register devices to an account, retaining the state of audio/video playback for their respective users. This allows users to move beyond simply downloading a video to play on a local stream; instead, they stream applications, and pause and resume video play on a variety of devices (e.g. multiple devices at home, tablets, TVs, media players).
Because of this, as video streaming usage increases, service providers are faced with tough challenges when offering scalable, latency free media experiences to large numbers of end users. Audio & video processing are compute intensive operations, and depending on the capabilities of the client device, can be taxing on power and performance. Video processing involves many operations like CSC (Color Space Conversion), up/down scaling, implementing standard codec profiles, implementing native media frameworks, rendering decoded video to display and transmitting encoded bit streams over networks. There are multiple options to offload this type of processing to higher compute machines, in order to ensure low end client devices can successfully stream and display high resolution content. CSPs with the service offerings to cost-effectively complete compute intensive operations by offloading can expect to capitalize on the high-growth cloud media market opportunity. And, by investing in cost-efficient, scalable and flexible solutions - like Celadon in Container, Intel’s open source Android distribution - CSPs can launch new media services with confidence.
Cloud Media Challenges
More media services are being delivered via cloud computing every day, requiring innovative solutions for efficient audio/video processing on client devices. A number of technical challenges face CSPs and Intelligent TV providers as they attempt to deliver cloud media services:
- Expanding file sizes. Advances in video technology - such as camera resolutions on mobile devices now reaching beyond 1080p to 4K - means video content takes up more storage space.
- Broad spectrum of devices. With more users watching media on a mix of devices, streaming content has to “just work” across a variety of smartphones, tablets, PCs, and beyond.
- Flawless user experience. Consumers expect a smooth, responsive viewing experience; therefore, service providers' infrastructure must support the latest transcoding codecs, such as High Efficiency Video Coding (HEVC) and V9.
- Cost efficiencies. Consumers expect continuous increases in services on their existing devices. This means service providers must optimize performance of their media streaming services to cost-effectively transcode and deliver content to users.
Overall, to successfully deliver high-quality content to end users, service providers must find ways to quickly and efficiently transcode video from one compressed format to another, while taking into consideration the requirements of an ever-increasing number of viewing devices with different bit rates, quality, and screen size requirements. This is where Celadon in Container can help. Celadon in Container (CiC) enables service providers to run containerized Android applications on Linux*-enabled Intel architectures, building the efficiency, quality and scalability necessary for enjoyable video streaming experiences in the cloud.
Figure 1. Cloud to device data streaming with Celadon in Container
Cloud Media with Celadon in Container
Figure 1 shows the software stack on the server side with multiple Android instances as Docker* containers. Each instance concurrently decodes video content, scaling it to the specific needs of remote end devices, then streams it via WebRTC (Figure 2). Here, running containers over Virtual Machines (VM) is optional - containers can be spawned over the host operating system if desired. The optimized vendor implementation of Android Hardware Abstraction Layer (HAL) is provided by Intel. This allows usage of graphics (extended / integrated) to be used for video processing operations such as up/down scaling, rendering decoded video to display, and other operations mentioned earlier. The goal is to spawn as many Android containers as possible without compromising Quality of Service (QoS) models. Frames per second (FPS) received at a user's device determines QoS and the FPS criteria is typically defined by the customer.
Typical codecs supported by this use case are H.264/AVC at HD or Full HD resolution, but this can vary. Depending on customer needs and applications, codecs can be extended to H.265/HEVC/VP9/MPEG. Additionally, decoding and scaling can be based on CPU or GPU type, depending on the availability of resources and support for hardware codecs.
Key Features and Optimizations
A variety of features were developed for Celadon in Container to support cloud media use cases.
Solution Features
Compressed video output streaming to end device – Video streaming can use a custom protocol or WebRTC-based transmission.
Video encryption support - Support includes CPU based video encryption or hardware accelerated video encryption. Figure 2 below depicts mechanisms provided by WebRTC; a software solution that provides CPU-based video encryption. RTP/RTCP protocols are used to initiate and transmit compressed and encrypted video to the client device.
Figure 2. WebRTC based streaming to client device
Instance status checking / Kubernetes* orchestration - The health indicator leverages Kubernetes to monitor the status of AIC instances for errors and stability issues, exposing issue information to the System Manager.
Remote event injection - This feature allows frontend device triggers - like specific gestures - to send control message requests to containerized video instances.
Solution Optimizations
Instance density - Launch multiple container instances and measure performance by exercising resource and interface bandwidth limitations.
User experience - Unified user experience regardless of Input Method Editor (IME) used in the host operating system and/or Celadon in Container.
End-to-end latency - Control input event to end-user video stream, ensuring latency is best suited for real-time video streaming performance.