Overview
| Artifact ID: | fbc148010a329edfed5c415a0b6780cea67259a753f9b198c9459a9fb23e188e |
|---|---|
| Ticket: | fbe8dbfcc230b567da3d6a8da157cc68961d3761
Fleet surfaces are O(repos) and will not survive thousands of stores |
| User & Date: | zeitgeist on 2026-09-12 15:57:54 |
Changes
- icomment:
Re-read 2026-09-12. The analysis still holds: repo.list takes a Limit but has no cursor and still walks every store to build the list before capping it, and people.list still fans out over Repos.Names(). Three things have changed around it, though. 1. Item 1's mechanism now exists as a worked example. The forum thread list was the same shape of wall — it rendered every thread — and now pages with a keyset cursor (activity DESC, root ASC) plus a separate count query for the total, one row over the page so 'is there a next page' is answered by what came back. Measured on fossil's forum: 26,736 KB and 264 ms became 393 KB and 55 ms. Worth copying rather than re-deriving for repo.list. Note the measurement surprise: the two SQL queries cost 72 ms together, so the wall was MARKUP (222,884 rect elements from per-thread sparklines and identicons), not the query. Any paging work here should measure which half it is before optimising. 2. Item 4 got its precondition. Index.Close() now waits for the rewarms it started instead of closing the database underneath them — an LRU of open indexes has to be able to close one while background work is in flight, and until now that was a use-after-close. 3. One cost went UP, which the ticket should know: search.all now also searches a bound forum companion (RFC 0015), so the fan-out is one extra index per bound pair, not per repository. Companion stores are otherwise filtered out of the dashboard listing and folded into their parent's facet, so a bound pair is one project to a reader and two indexes to the fan-out. The 23-store measurements in the table are also now stale in composition rather than in kind: pkgsrc was added (218,590 records, 1.1 GB of index) and it is the store that would dominate any per-repo fan-out timing.
- mimetype: "text/x-markdown"