Technologists have long considered Peer-to-peer (P2P) technology a natural fit for real-time applications since they have intrinsically lower latency than traditional client-server applications: Nodes can communicate directly without the need of relaying the content through a server in the cloud.

This has the potential to greatly reduce infrastructure costs and improve user quality of experience. Many commercial VoIP and video conferencing applications are already using P2P technology in various forms, and offerings are continually coming to market, including video distribution and software updates. However, P2P solutions have traditionally required the installation of additional client software or browser plugins. This hinders adoption by casual users, as new adopters are forced to download and install an additional client software, and this comes with all of the usual hurdles of keeping installed software up-to-date. Fortunately, with the advent of the WebRTC standard, this limitation is soon to disappear.

WebRTC defines a set of APIs, to be included in all browsers, which enable the development of browser-based real-time P2P application – in particular VoIP and video conferencing – simply by writing client-side HTML5 code. WebRTC therefore completely removes the need for third-party plugins or client-side software installation and allows frictionless deployment of new P2P-based services as JavaScript applications. In addition, WebRTC makes it easy for developers to deploy new versions of their code – and for users to always have the latest version – simply by updating a webpage’s code.

WebRTC is really a set of utilities, the most important of which is peer-to-peer connectivity. WebRTC makes it possible for HTML5 applications to create a direct connection between browsers running on hosts in totally different networks, even though the hosts may be behind Network Address Translators (NAT) and therefore not directly reachable.

In addition to P2P connectivity, WebRTC provides a Swiss Army Knife-style toolbox for video and audio handling. The purpose of these utilities is to enable seamless in-browser video conferencing and VoIP. A WebRTC app can record video/audio using a computer’s webcam/mic, encode it efficiently in real-time using a machine’s CPU and GPU, encrypt it and transport it on an encrypted connection to the receiver(s).  The best part is all of these tools have already been optimized for various devices types, from smartphones and tablets to high-end workstations. Besides multimedia-specific use-cases, WebRTC also enables the development of all sorts of other P2P applications. This is done by allowing the transfer of arbitrary data over P2P connections established with the framework. Once this feature became stable, a plethora of new applications were developed on top of it. Examples include, but are definitely not limited to, file sharing, CDN accelerators and instant messaging.

How do I get WebRTC?
Currently, stable WebRTC implementations exist in three major browser distributions: Chrome 23+, Firefox 22+ and Opera 18+. Internet Explorer is poised to support a standard with similar features in Windows 10, called ORTC. In addition, an agreement has been reached between Google, the main sponsor of WebRTC, and Microsoft for interoperability between the two standards.

Hive Streaming and WebRTC
At Hive Streaming, we are already using WebRTC to do what we do best: distribute video. In my next post, I am going to describe how we leverage WebRTC and delve into the pros and cons of application development with this new standard.

Roberto Roverso
Head of Research & Developement
Hive Streaming