Http2与Http1.1比较

Key Features

HTTP/2 has the following key features compared to HTTP/1.1:

  1. Binary Protocol 二进制协议
    HTTP/2 is a binary protocol. This means that it is much more efficient on the wire, however as a result it is no longer human readable without using tools to decode the protocol.

  2. Multiplexing 多路复用
    HTTP/2 supports multiplexing several streams over a single connection. This means that a client can send multiple requests on the same connection, and the server can respond in whatever order the responses become available.

  3. Header Compression 头部压缩
    HTTP requests and responses generally include a large number of redundant headers. HTTP/2 uses HPACK header compression to greatly compress headers.

  4. Server Push 服务端push
    Server push allows a server to send additional cacheable resources to the client that the client has not explicitly asked for. The allows the server to anticipate the resources the client will request next and send them eagerly, which saves a round trip.

An in depth overview of HTTP/2

你可能感兴趣的:(Http2与Http1.1比较)