What is HTTP/2 multiplexing and what problem does it solve?
Sketch your own answer first, then compare it with the one below.
A strong answer
HTTP/2 splits one connection into streams. Many requests and responses are in flight on the same connection at once, with their frames interleaved.
With HTTP/1.1 a connection serves one request at a time, so a client needs many connections for parallelism, and requests wait when they are all busy. Multiplexing removes that wait, needs fewer connections and fewer handshakes, and lets header compression work across requests.
Sources
- Martin Thomson, Cory Benfield (2022). RFC 9113: HTTP/2.