zz_

a2074e5d ยท zzmq.dev@gmail.com/zz

Commit

a2074e5d8f84219656027451f053fa55c6428f4b

Fix Ladder-tab slowness: cache root commit oid, share notes-ref checkouts across sibling reads Instrumented a live repo page load end to end to find what the earlier zz-meta fetch fix didn't cover. Found two real, separate costs inside the Ladder tab's DO round-trip (getLadderTree): 1. Every "_repo" rung read re-derived the repo's root commit oid via a fresh repo.log({limit:1000}) fetch (anchorShaForRung's "repo" case) -- wasteful since the root commit never changes once a repo has any history. Cached in the DO's own durable storage (not an in-memory closure, since MaintainerDO.configure rebuilds the whole Backend object on every call). 2. getLadderTree resolves the root's top-level children one DO call at a time, and several of those children share the exact same underlying git-notes ref (every file/directory/function/lines rung uses the one "code" ref) -- each call was re-running scopedNotesCheckout's real git fetch of that identical ref from scratch. For shoes (3 files + 2 changesets) that was 5 redundant checkouts where 2 would do. Added a NotesCache shared across every readRung call within one readAnchorFor-driven batch. Measured live: the Ladder/Lane DO round-trip dropped from ~3.4-4.7s to ~2.2-2.8s, and total repo-page load from ~4.5-7s to ~2.7-3.2s.

Troy Howard <thoward37@gmail.com> -- 2026-10-13T03:57:27.000Z

Tree at this commit