A layer is Go's usual middleware shape, a function that wraps the next one,
so it composes with anything already written that way and needs no framework
knowledge to write.
Work before calling next happens on the way in, work after it on the way out,
and not calling it at all short-circuits, which is how a cache layer answers
without reaching the handler.