prerender-v0.93.0 — @harperfast/prerender
·
110 commits
to main
since this release
The render queue is now an in-memory queue keeper, with RenderSchedule as its durable side (#219, #215). The nextRenderTime index and everything built around it are removed: the claim floor, the ready sweep and the capped backlog walk.
Behaviour
- Worker 0 holds every schedule row this node owns. It loads them by primary key, keeps them current from a table subscription, and publishes the ready set every second. It never reloads once live: config and membership changes reclassify in memory, and a lost subscription is reopened and walked.
- Claims take from the ready set, re-read each row, and lease it with an exclusive grant, with no mutex. A key whose leases keep expiring with no result is held back (2, 4, 8… leases, capped at its cadence) rather than granted again.
- A new queue status,
unready, is reported while the keeper is not serving. Deployed renderers read it asempty.
API
- New
GET /prerender_admin/queue-state(node-local). overview.claimFlooris replaced byoverview.leases, andexplainandscheduledropclaimFloor/belowClaimFloor.- Removed: the
reset-claim-flooraction and thecaponPOST /prerender_admin/backlog.
Config removed
queue.claimFloor.*, queue.claimScanCap, queue.ready.enabled, queue.ready.sweepInterval, queue.ready.sweepCap. A removed key that is still set only logs a warning.
Config added
queue.keeper.{publishInterval, verifyInterval, stateInterval}.
Metrics
- Removed
queue_healthseries:claim_scan_ms,ready_sweep_ms,ready_published,ready_cadence,below_floor,below_floor_age_ms,floor_pin_age_ms. - Added:
keeper_load_ms,keeper_publish_ms,keeper_verify_ms,keeper_repaired,keeper_live,claim_stale,claim_wedged.
Deploying
- Upgrade in place, with no data migration. A cluster running both versions is safe, so a node at a time works.
- A rollback takes two restarts per node. 0.92.0 re-adds the index, and on a multi-thread node harper-pro#681 can leave some threads failing claims with
"nextRenderTime" is not indexed yetafter the rebuild. Restart once more once the rebuild finishes. - Console 0.17.0 keeps working, but its floor and sweep panels read
—until the console catch-up.