InfrastructureLesson 2 of 48 min

The domain, and the plumbing under it

Four separate things that everybody assumes are one thing, with four separate ways to fail.

Your address looks like one purchase. It is four arrangements with up to four different companies, each with its own account, its own bill and its own way of going wrong.

What happens when somebody types your name
  1. The registrar
    Who you rent the name from. You never own a domain; you hold it until a renewal date.
  2. DNS
    The directory that turns the name into an address. Answers are cached all over the world, which is why changes are not instant.
  3. The host
    The machine or platform that actually answers at that address and serves your app.
  4. The certificate
    What makes it https rather than a browser warning. Usually issued and renewed for you, silently, until it is not.

Changes are slow for a reason. Every DNS answer carries a time to live, and until it expires, resolvers keep serving the old answer from cache. Lower the time to live a day before a planned move and raise it afterwards. This is the same caching idea from the shipping course, wearing different clothes: "it works for me" is often somebody holding a fresher answer than you.

Sounds like a name problem

  • The site is unreachable, no error page at all
  • It works on your phone but not your laptop
  • It started exactly when a record changed
  • A browser warning about the certificate

Sounds like an app problem

  • The page loads, then something on it fails
  • Everyone sees the same thing at the same time
  • It started exactly when you deployed
  • The host dashboard is showing errors

Who do I pay for my domain, and what date does it renew?

A surprising number of people cannot answer either half, which means nobody is watching the one date that turns everything else off at once.

What to remember

  • Registrar, DNS, host and certificate are four things with four failure modes.
  • DNS changes are slow because answers are cached until their time to live expires.
  • Losing the domain takes down a perfectly healthy app, and is slow to undo.

Terms in this lesson

Field notes

Loaded from a deliberately slow source. The lesson above was already readable while this was still travelling. That is streaming, and it is the same trick a chat interface uses.

The digest that stopped for five weeks

A weekly email job silently stopped running after an infrastructure change. Nobody noticed, because a job that does not run produces no error. It was discovered when a customer asked whether they had been unsubscribed.

Why you alert on missing success

Everyone retried at once

A service had a brief wobble. Every client retried immediately, then again, then again. The retries were far more traffic than the original load, and the service never got a quiet moment to recover. The outage lasted forty minutes longer than the fault did.

The thundering herd

resolved in 899ms · region iad1

Hide field notes toggles a search param the loader reads. With it off, the slow promise is never created, so nothing streams.