Do you know the differences between different versions of HTTP protocol?

Do you know the differences between different versions of HTTP protocol?

[[420148]]

Introduction

There are already multiple versions of the HTTP protocol. Generally, the websites we visit use either HTTP1.1 or HTTP2. What is the difference between them? Why don't all websites use the same protocol?

Version

Up to now, IETF has released 5 HTTP protocols, including HTTP0.9, HTTP1.0, HTTP1.1, HTTP2, and HTTP3. Here are the differences between the versions:

HTTP0.9

Released in 1991, it has no headers, is very simple in functionality, and only supports GET.

HTTP1.0

Released in 1996, it has poor plaintext transmission security and a very large header. It has the following enhancements compared to 0.9:

  • Added header (decoupling metadata from data)
  • Added status code to indicate the result of the request.
  • Content-type can transfer other files.
  • The http/1.0 version number is added to the request header.

Disadvantage: A new TCP connection is created each time a resource is requested

HTTP1.1

Released in 1997, it is the most widely used version now. It has the following enhancements compared to 1.0:

  • You can set keepalive to let http reuse tcp connection (requests must be sent serially)
  • Support pipeline transmission, and you can continue to send requests after the request is issued
  • Added the HOST header to let the server know which domain name the user requested
  • Added headers such as type, language, encoding, etc.

Updated in 2014:

  • Added TLS support, i.e. https transmission
  • Supports four models: short connection, reusable TCP long connection, server push model (the server actively pushes data to the client cache), websocket model

Disadvantages: It is still a text protocol, and both the client and the server need to use the CPU to decompress it.

HTTP2

Released in 2015, it mainly improves security and performance. Its enhancements compared to 1.1 include:

  • Header compression (merging identical parts of requests sent simultaneously)
  • Binary frame transmission, more convenient for transmitting only the difference part in the header
  • Stream multiplexing, only one connection is needed for the same service, saving connection
  • Server push, the server can respond multiple times to a client request.
  • Can send requests concurrently in one TCP connection

Disadvantages: Based on TCP transmission, there will be head-of-line blocking problems (packet loss stops window sliding), TCP will retransmit lost packets, TCP handshake delay is long, and the protocol is rigid.

HTTP3

Released in 2018, based on Google's QUIC, the underlying layer uses the udp code tcp protocol.

This solves the head-of-line blocking problem, and there is no need for handshakes. The performance is greatly improved, and TLS encryption is used by default.

<<:  Breaking news: Why has Huawei LampSite won the GlobalData Indoor Small Site Rating for three consecutive years?

>>:  How many people are using invalid 5G? The price has doubled, and the experience has become worse

Recommend

IPv6 conversion service - rapid business support for IPv6 practice

What is IPv6 conversion service? IPv6 Translation...

The importance of China building 5G networks ahead of the United States

China may build a 5G network before the United St...

5G is here, and these threats are lurking...

5G is coming, and it will be possible to experien...

165 million! China Mobile’s 5G user number announced, is 4G really outdated?

[[377452]] On January 20, China Mobile announced ...

What is 6G? It may appear in 2030, crushing 5G without any pressure

5G has already been deployed, so what about 6G? W...

Can the heavy fine on Alibaba serve as a wake-up call for the Internet giant?

The State Administration for Market Regulation ha...

Is your home router safe? Tests on 18 routers tell you...

Fearing Wi-Fi radiation, parents asked schools to...

Traditional Networks vs. IoT Networks: What’s the Difference?

IoT provides businesses with greater visibility, ...

Common ways to manage networks through AIOps

NetOps teams in enterprises are faced with the ch...

Is the United States blocking Huawei, or the entire future of 5G?

[[349279]] The United States is creating obstacle...

5G is the new infrastructure, but it also faces practical problems

Labs Guide When we browse Moments and watch video...