Cianplan

Level 0: Orientation & prerequisites · L0.3 Networking: TCP/IP, TLS, HTTP/2/3, QUIC

Counting round trips (a latency budget)

Add up DNS, TCP, TLS and request round trips for a first page load.

10 min · Free

What you take away

  • A first page load is a handful of round trips: DNS, TCP, TLS, then the request itself.
  • Multiply the round trips by the user's RTT before blaming the server — setup usually dominates a first visit.
  • There are only three moves: remove trips, shorten trips, or overlap them.
  • A repeat visit skips almost all of it, which is why first-visit numbers are the ones worth budgeting.

How the class is laid out

  1. The problem
  2. The simple version
  3. Where a first visit's time goes
  4. The only three moves
  5. TCP vs UDP
  6. TLS 1.3
  7. HTTP versions
  8. Latency budget
  9. Check your understanding