multiplexing

All request data can be transmitted over a single TCP connection.

– Fixed browser restrictions on the number of requests in the same domain (typically six in Chrome)

How it works: Multiple streams can exist in a TCP connection. In other words, multiple requests can be sent, and the peer can know which request belongs to by the identifier in the frame. With this technique, the queue header blocking problem in older versions of HTTP can be avoided and transport performance can be greatly improved.

Binary transmission

The Header compression

In HTTP /2, the HPACK compression format is used to encode the transferred headers, reducing the size of the headers. An index table is maintained at both ends to record the headers that have appeared. Later, the key names of the recorded headers can be transmitted in the transmission process. After receiving data, the peer end can find the corresponding value through the key names.