HTTP/2 is coming. And here’s what you should know

Karthik Kamalakannan
Sudo vs Root

--

Even though the web browsers might have gotten smarter, and the mobile revolution has happened since 1999, the specifications of HTTP has been the same. HTTP/1.1 was released back in 1999 to push the web technologies forward. And it was huge back then. But today, we live in a age where the amount of data being transferred is humongous, from the browser to server. The practice of the server waiting for the browser to request data is now over with the new HTTP specification which is already there in the wild in some browsers and servers.

Let’s quickly take a look at how this will affect you and why this specification is very important.

How HTTP/2 happened

As the web technologies grew, and as the amount of data that the browser is handling increased, we had an important problem to solve. So the engineers at Google started working on an interesting project called SPDY (pronounced as speedy). The announcement excited people like us, as the title read:

A 2x Faster Web

And here’s what the post has about the project:

We started working on SPDY while exploring ways to optimize the way browsers and servers communicate. Today, web clients and servers speak HTTP. HTTP is an elegantly simple protocol that emerged as a web standard in 1996 after a series of experiments. HTTP has served the web incredibly well. We want to continue building on the web’s tradition of experimentation and optimization, to further support the evolution of websites and browsers. So over the last few months, a few of us here at Google have been experimenting with new ways for web browsers and servers to speak to each other, resulting in a prototype web server and Google Chrome client with SPDY support.

Right after the project went live, we saw the increase in performance of some of the biggest platforms we ever use, like Twitter, Facebook and LinkedIn. The adoption rates were huge that the need to make this a standard grew.

HTTP/2 Specification

HTTP/2’s specification adopts the SPDY’s features heavily, and here are some of them:

Security

HTTP/2 is probably the best thing that has happened to the web. The new update comes with the best practices of HTTPS and TLS 1.2 is a requirement for HTTP/2. This is not all, the new spec also eliminates the requests with a weak cipher.

A while ago, there was a healthy discussion about making HTTPS a requirement for HTTP/2, but it was later decided that it will not be a requirement for HTTP/2.

As of today, SSL/TLS for HTTP/2 is already supported in browsers like Google Chrome and Mozilla Firefox.

Concurrency and Multiplexing

With HTTP/2, the servers can receive requests from the browsers that can be sent in a very rapid succession on the very same TCP connection. And it is not necessary that the requests should be in an order, thus eliminating the biggest problem of having to open multiple connection to the server from the client when transferring large amount of data.

This feature has actually helped us push the technology forward at the stack we use for SHRINK, and we have seen a huge bump in the performance.

Prioritizing the Streams

It is now possible for the client to prioritize the resources that are required. The headers can now contain these parameters to prioritize these resources.

Better Compression

As the web exploded, the time it took to transfer the headers grew up, since every single request has its header sent constantly. This in turn increased the load times, and it was a huge hassle for the developers. But with HTTP/2, the size of the HTTP header has been reduced drastically, by taking advantage of the best compression algorithms on the planet.

Server Push

This is something that is truly revolutionary. In short, the servers can send multiple responses to a single client. Currently, a web page loads resources like CSS, JS, Images and Fonts. This increases the load time of a website exponentially, since the server was capable of serving only one request at a time per client. But now, this limitation is gone.

If you are a system admin or a developer, it is very important to understand that Server Push is not Server-Sent Events. Unlike SSE, the requests and responses are handled by the browser and not the application’s code.

Our take on HTTP/2

We have been testing HTTP/2 on Evolvr.io and SHRINK for a while, and we were able to improve the load time and security drastically. While we might have to wait for the official announcement of HTTP/2, we are certain that this will help companies scale up easily for the next decade. You can get some information about HTTP/2 here.

Originally published at blog.skcript.com.

--

--

Karthik Kamalakannan
Sudo vs Root

Co-founder & CEO of @SkcriptHQ. Building Hellonext.co. I write about building a bootstrapped SaaS business.