A System Design in Forty Minutes
Justifying Every Box in the Drawing With the Number That Forced It
Last timeWhat You Promise When It Breaks
How to draw a final design in which every component can be defended by the estimate that forced it, which boxes to leave out, and what to change first when one estimate moves.
A final drawing is a transcription, not a design. By the time it is drawn, every
decision in it has already been made by arithmetic, and the drawing's only job
is to hold those decisions where both of you can see them. That is also what
makes it defensible. Asked why a component is there, you are not being asked
for an opinion about that component. You are being asked for a number, and
either you have it or the box was decoration.
The numbers the drawing answers to
The brief is a link shortener with click analytics, and the estimates were
settled before anything was drawn. There are 100,000,000 new links a day, and
since a day is 86,400 seconds that is a
second, rounded up to 1,200 writes a second. A link is followed about 100 times
over its life, so redirects run at a second at
the mean. Peak is three times the mean, giving
writes and reads a second. A link row is 500
bytes, so storage grows by GB a day and
GB a year, which is 18 TB. Every redirect also
records a click event of 100 bytes, so clicks arrive at the same 360,000 a
second at the peak and occupy TB a day,
or 365 TB a year. The read to write ratio is 100 to 1.
Against that, one machine does 10,000 reads a second from memory, 5,000 writes
a second to a store that goes to disk, and holds 1 TB of usable disk. Those
three numbers and the six above are the whole of what the drawing has to
answer to.
Every box is one division
The whole defence is one piece of arithmetic applied repeatedly, and it has
three parts: a demand , a capacity and the machine count that falls
out of dividing one by the other.
The lesson stops here
7 more paragraphs to go
You have read the opening. The rest of the argument, the problems that check whether it landed, and the lines worth keeping at the end all come with a plan.
The first lesson of every course in the library reads the whole way through, free, so you can see exactly what the rest of them are.
See the planThe contentsThis is the reading half
Starting the course gives you your own copy of it. Every idea on every page has problems standing under it, marked with a reason rather than a tick, and any sentence you do not believe can be opened and argued with. None of that can happen on a page nobody owns.
The contents