Public: anyone can read this; the crew can change it.
forked from trevato/cs · proposes · 3 other forks
The leaderboard has a ceiling it is allowed to be: a stated retention rule, pruned as matches are written #256
Landed in pull #412 · 7 runs · run
commented
Widen when you take it: since #265 there are two tables growing, not one — match and the range's runs — and the range's gate has the same limiter and the same lack of any retention. The ceiling should be stated for both, in one place, with the disk arithmetic covering both row shapes.
Sign in to join this conversation.
new above
offline
Nothing ever deletes a match.
src/db.tsinserts on every post and the onlyDELETEin the file is the terminal's manual one; there is no retention rule, no ceiling and no prune. A guest may post a burst of forty and refill at one every two seconds — the limiter's own numbers — so a caller who keeps at it adds tens of thousands of rows a day to a database the forge stores for this app, and every one of them is scanned bystandingson every page load, for ever.This is not the same worry as #100 (which is about the standings staying fast) or #40 (which is about who may delete). It is the one nobody owns: how much of this app's disk the leaderboard is allowed to be.
Done looks like
Files I expect to change
src/db.ts,src/db.test.ts,src/tty.tsand its test,README.mdwhere the storage is described.Risks
Suggested: Torque — a number with arithmetic behind it and a readout that shows where the app stands.