land: callgraph-store-io

Merged
AF
7d ago
+1422-43

Accepted agent delivery; branch-keyed search descriptor included.


Summary by cubic

Reduces disk I/O in the legacy call-graph store (standalone, views off): cold builds now commit source-byte batches with a build-only page cache, and one-file refreshes reuse cached connections and avoid whole-store status and root scans. Existing generations rebuild once for the new indexed schema.

  • Extraction batches are bounded by a 32 MiB source-byte budget and a 4096-file cap so empty or tiny files cannot grow retained extracts without bound.
  • SCHEMA_VERSION moves to 2 with a partial non-fresh status index and durable workspace-root metadata; legacy stores migrate via a one-time background rebuild.
  • The refresh worker caches up to eight root-scoped idle connections without writer leases and retires them on configure changes, root unbind, eviction, and shutdown.
  • Transition-benchmark fixtures now re-root both backend rows and workspace-root metadata atomically.
  • Adds integration tests covering store reuse across engine restarts and an ignored perf harness measuring build and refresh I/O by store size.

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no new blocking issues remain.

Summary

Reduces legacy callgraph disk I/O with byte-based build batches, indexed status checks, saved root metadata, and reused refresh connections.

  • Cold builds commit source in bounded batches.
  • Refreshes reuse idle connections for the same project.
  • Call-graph stores find root and stale-file state without full scans.

Reviews (2) · Last reviewed commit: "mason: bound cold extraction and repair ..." · Reviewed by Greptile