From 24fe2003b6299ad8b81d543291ddf7ba19e9bae7 Mon Sep 17 00:00:00 2001 From: michilis Date: Tue, 25 Aug 2026 16:29:09 +0200 Subject: [PATCH] Drop the nightly rebuild timer. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The timer was load-bearing while the mint list was a build-time snapshot: a rebuild was the only way a new mint, a new review count or a changed status ever reached /mints. The list hydrates now, so all three arrive within a second of load, in every language, and rebuilding 2,000 pages at 03:30 to refresh numbers that refresh themselves is twenty minutes of CPU for nothing. cashumints-web.service stays exactly as it is — it is the deploy-time publish step, and now the only thing that starts it is a deploy. A build still produces what only a build can: the prerendered HTML a crawler reads, a social card per mint, the sitemap and hreflang set, and a /mint/{host} page for every mint known at build time. The one thing that gets staler is that last item. A mint indexed since the last deploy has no prerendered page: /mint/newhost is a 404, whose resolver looks the address up against the live API and renders it — readable, reviewable, noindex until a deploy gives it a real page. That was already true between nightly builds; this only lengthens the window. README documents the one-time host commands to remove the installed timer, and gains a "Live lists" section describing what replaced it. Co-Authored-By: Claude Opus 5 --- README.md | 107 ++++++++++++++++++++++++++++------ deploy/cashumints-web.service | 30 +++++++--- deploy/cashumints-web.timer | 25 -------- 3 files changed, 110 insertions(+), 52 deletions(-) delete mode 100644 deploy/cashumints-web.timer diff --git a/README.md b/README.md index e2bc9f4..776ee63 100644 --- a/README.md +++ b/README.md @@ -296,7 +296,52 @@ Three packages in order, and the order is a dependency chain rather than a habit `shared` emits the types and the warning copy both other packages import, `api` compiles `api/src` to `api/dist`, and `web` prerenders against a running API. -Output lands in `api/dist/` and `web/dist/`. Every page is prerendered once per language, so ~55 mints +Output lands in `api/dist/` and `web/dist/`. + +### Live lists + +The prerendered mint list is a snapshot of what `GET /api/mints` said when the build ran. +It used to stay that until the next build, which is why there was a nightly timer: a mint +indexed at noon was reviewable at once — the 404 resolver saw to that — and had no card on +`/mints` until 03:30, beside cards whose ratings and statuses were equally old. + +`/mints`, `/fedimints`, `/lnurl-mints` and the home page's three top-six strips now refetch +that endpoint once, after paint, and rebuild their grids from the answer. One request per +page, no relays involved: card counts have always come from the API's ingested review +aggregates, and review *bodies* remain a mint page and `/reviews` concern. + +**The prerendered cards stay.** They are the first paint, they are what a crawler indexes, +and they are the whole page for a reader with no JavaScript — `