The paste expired. The cleanup job is hours behind. Can anyone read it?
transcript
A paste was set to vanish after 10 minutes. The cleanup job is a few hours behind. Can anyone still read it?
Don't trust the cleanup job for correctness. Check on every read. Expiry passed? 404. Even though the row still exists. Not yet? Serve it. The answer is right, however far behind the sweeper is.
But here's the catch. The CDN and Redis serve without asking you. A copy cached for an hour would outlive a 10-minute paste.
So expiry lives at every layer. One: check on read, for correctness. Two: cap every cache TTL at the time left. Three: a sweeper every minute deletes blobs, then rows. Only for space.
Walk one through. Created with 10 minutes to live. Every cache copy is capped at those 10 minutes. At 10 minutes, a read checks the time. 404. Whenever the sweeper gets there, the blob goes. Then the row.
Cleanup is for space. The read check is for truth. The sweeper can lag. The answer can't.
Full breakdown in the lecture.