Telling Whether It Earns Its Place
Last timeWhen There Is More Than One
The hit rate is the number everybody watches and the one that answers the fewest questions. What you want to know is what the cache saved, what it still fails to save, and what more of it would buy.
Every cache reports a hit rate, and it is the first number anybody looks at. It
is also the number least able to answer the question people are asking, which is
whether the cache is worth what it costs and what to do next.
What the hit rate leaves out
A hit rate counts events and weights them all the same. One hit on an answer that
would have taken two seconds counts exactly as much as one hit on an answer that
would have taken a tenth of a millisecond.
- the work avoided per second, in whatever unit the work is measured
- the read rate
- the hit rate
- the cost of producing one answer when it is not held
- the hits per second, which is what a hit rate alone gives you, missing the third factor entirely
So the measurement worth keeping is not the hit rate but the product. In
practice that means recording, per kind of answer, how many hits it took and what
a miss on it costs, and reporting the saving. A cache whose hits are all on
expensive answers can be enormously valuable at a hit rate people would describe
as broken.
The lesson stops here
4 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