Chapter 14: Data and failure

Graceful degradation

Also called Load shedding

Doing less when part of the system is unwell, in place of falling over. Hide the recommendations, serve a slightly old list, turn off the search, and keep the page up. You decide in advance what the product can live without, and what it can't.

An agent's default is to wait for everything and then render, so one optional panel can take down your whole checkout. You have to name which parts are optional. And you have to name what must never be faked: a stale recommendation is fine, a stale price at the moment of paying is not.

Say it to your agent

“The product page must render if reviews or recommendations are down: give each a 200 ms budget and a fallback, and log and count each fallback used. The price is not optional. If it's unavailable, turn off buying and say why. Test each with the dependency switched off.”

The workshop

Name a word, or describe what you mean in everyday language.