We all accept the fact that we need to improve the performance of our website and any improvement over HTTP protocol can provide a great opportunity to improve the website load time significantly. It can be termed as one of the great ways to beat our competition, which will eventually help improve the user experience on our website.  Before we deep dive on HTTP/2, and its benefits, let’s understand what a protocol is by definition and why it’s important.

 

What is a Protocol

A protocol is a set of rules which governs the data communication between clients (web browsers) and servers. Now using this same protocol we previously had HTTP 1.0 and now we have its improved version called HTTP 2.0. Additionally, there is HTTP/3, but currently in “draft” mode. According to W3Techs, only 6.5 percent of websites use HTTP/3.  Chrome and Firefox currently support HTTP/3, but it is turned off by default.  HTTP/3 will help to address some issues with HTTP/2, like head-of-line blocking, which causes all transactions to stall if a packet is lost or reordered, even if that transaction wasn’t impacted by the lost packet.

 

What is HTTP/2?

HTTP/2 is the latest protocol for transporting data which has drastically speed up the web. HTTP/2 will make our websites faster, simpler and more robust to heavy traffic. The primary goal of HTTP/2 is to reduce latency by enabling multiplexing on request and response, minimizing the protocol overheads via efficient compression of HTTP header fields and support for request prioritization.

And just a separate note: HTTP/2 has not changed anything with HTTP semantics, by this we mean HTTP methods, status code, URIs and header fields remain as it was before, which helps all running applications with no impact.

 

Where Did HTTP/2 Come From?

HTTP/2 was based largely on Google’s own protocol SPDY. The protocol had many of the same features found in HTTP/2 and managed to improve data transmission while keeping backwards compatibility with HTTP/1. SPDY had already proven many of the concepts used in HTTP/2.

What’s new in HTTP/2

  • Binary instead of Textual
  • Server Push
  • One connection instead of multiple
  • Prioritization of multiplexed streams
  • Header specific compression
  • Fully multiplexed requests

 

Key Benefits of HTTP/2

  • Multiplexing.  Multiple Request per Connection: Multiplexing in HTTP/2 allows the client to load multiple requests on the same connection, allowing a faster, concurrent load time for all the web elements.
  • HPack Compression.  HTTP/2 transmits server requests and responses in binary code, which keeps the client to interpret the sent information. This improves both load time and general performance.
  • Prioritization.  Prioritization allows developers to allocate dependency levels for their code, they get feasibility to load essential resources first.
  • Backed by Google.  HTTP/2 has followed the same principles of SPDY.
  • HTTP/2 Server Push.  This capability allows the server to send additional cached information that isn’t requested but anticipated in the next request.

 

HTTP 2.0 Load Test with LoadView

We will be using Loadview, which provides support to stress test HTTP 2.0 based websites and spin up anywhere from a few to several thousand concurrent connections using real browsers. It’s the best way to get real user performance data.

 

LoadView Performance test Setup

To scale and load tests for your website we would need to understand beforehand what scale or user count we are expecting on our website to work seamlessly. Once we have the data from the analytics tool, we can start a step by step load test for our website with the desired concurrent users.

Here are the steps to run a load test for an HTTP 2.0 based website:

  1. Open LoadView homepage and select New Test.

Create New Load Test

 

  1. As you can see in the screenshot below, LoadView provides load testing for more than just websites.  You can run tests for APIs, web applications, and streaming media.  We’re going to select the Web Page to begin the process of load testing our HTTP 2.0 website.

Web Page Test

 

  1. On the next page, we’ll need to add our website host name as well as  the time we need load test to run. Once you’ve got your details entered, select Create Device.

Create New Load Test Device

 

  1. Once the device is created, we’re brought to the Test Scenario page, where we can choose from multiple types of load curves – Load Based Curve, Goal Based Curve, and Dynamic Adjustable Curve.  Depending on the requirements for your specific test, each load curve provides you the flexibility to meet the goals for your test.

Test Scenario Screen

 

  1. For this test, we’ll select the Load Step Curve and enter the details of the execution plan, like how many users we want to start with, how many we want to raise to, and then hold that for an extended period of time, if necessary. Once we select Continue, this will start the load test.
  2. Once the test has completed successfully, we’ll be able to view various graphs and metrics to see how our website and system performed. You’ll see response times, concurrent users, and errors, if any occurred during the test. This gives us the data we need to make enhancements to ensure that our systems can handle the required number of users we set out to test.

Average number of users average response time

 

HTTP2 average response

 

HTTP2 execution plan

HTTP 2.0 Load Testing

HTTP/2 will make our websites faster, simpler, and more robust to heavy traffic. The primary goal of HTTP/2 is to reduce latency by enabling multiplexing on request and response, minimizing the protocol overheads via header field compression, and support for request prioritization. Not only that, sites that utilize HTTP/2 are will see higher search rankings as Google uses them in their ranking factors.

Testing the performance of your website can sometimes be an arduous process, but it’s critical to understand how you site responds to increases in traffic. However, using a solution like LoadView to test and validate the performance of your HTTP/2 website can make the whole process easy and effortless. With support for the latest protocols and technologies, you can ensure you users get the fast and consistent experience they deserve.

If you would like to run performance tests for your HTTP/2 websites tests in LoadView, you can sign up for a free trial to get free testing.  Get started testing now!

We also offer private one-on-one LoadView demos with one of our performance engineers. They can guide you through the setup, scripting, and testing process.  Get a comprehensive overview of the LoadView platform, its features, and capabilities.