Web Technology Basics

Which of the following correctly describes HTTP/2 and HTTP/3?

  1. AHTTP/2 can handle several requests in parallel over one TCP connection, but a packet loss can make other streams wait too; HTTP/3 reduces this with QUIC over UDP
  2. BHTTP/2 uses messages in the same text format as HTTP/1.1 and opens a new TCP connection in parallel for each request, so that several resources can be received at once
  3. CHTTP/3 runs over TCP like HTTP/2 and only changes the header compression method; the effect of packet loss is the same as in HTTP/2, and it does not use UDP
Show answer and explanation

Answer: A. HTTP/2 can handle several requests in parallel over one TCP connection, but a packet loss can make other streams wait too; HTTP/3 reduces this with QUIC over UDP

Even HTTP/1.1 can reuse one TCP connection with persistent connections (keep-alive), but responses on one connection are received one at a time in order, so browsers opened several connections in parallel. HTTP/2 splits messages into binary frames and multiplexes several streams over one TCP connection so they are sent in parallel. However, because TCP delivers its byte stream in order, when a single packet is lost, data of unrelated streams must also wait until the retransmission arrives (head-of-line blocking). HTTP/3 uses QUIC, which runs over UDP and manages ordering per stream, so the effect of a loss stays within that stream.

  • A. Correct. HTTP/2 can send in parallel by multiplexing, but a loss in TCP affects all streams. HTTP/3 reduced this with QUIC.
  • B. HTTP/2 uses binary frames and multiplexes several requests over one connection. Opening new connections is actually slower.
  • C. HTTP/3 uses QUIC, which runs over UDP, not TCP.
Practice this topic Back to topic

Books on Web Technology Basics Ad

As an Amazon Associate I earn from qualifying purchases.

More Web Technology Basics questions

  1. From a web server with an RTT of 40 ms, one HTML file and the four images it references are fetched one after another. Assume that establishing a TCP connection takes one round trip and each request and response take one round trip, and ignore data transfer time, server processing time, TLS and connection teardown. Which of the following is the difference in total time between opening a new TCP connection for each object and reusing one TCP connection (a persistent connection)?
  2. HTTP is a stateless protocol. Which of the following correctly describes what this means together with the usual way a website keeps a user logged in?
  3. Which of the following correctly describes the cookie set by the header above?
  4. Which of the following correctly describes a difference between the browser's localStorage and cookies?
  5. Three application servers are placed behind a load balancer, which distributes requests to them in turn (round robin). The session information of a logged-in user is stored only in the memory of the server that handled the login. Which of the following is an appropriate pair of a likely problem and its countermeasure?