feat(storage): report nested depth so Forgejo's split needs no kubectl exec #28
No reviewers
Labels
No labels
burndown-2026-08
autonomy
async-consult
autonomy
epic
autonomy
headless
autonomy
live-collab
coherence-core
priority
P0
priority
P1
priority
P2
priority
P3
priority
P4
qa-fixture
role/advocate
role/director
role/exec
role/frontend
role/gamedev
role/human
role/platform
role/qa
role/science
role/sysadmin
state
ambient
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
coilyco-flight-deck/node-stats-mcp!28
Loading…
Reference in a new issue
No description provided.
Delete branch "aos/claude/uq98-usage-depth"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Follow-up to #27, which is merged. Refs #26.
#27 fixed the OOM and added the
pod-ephemeraldomain, which took four of the incident's eight manual commands unattended. It did not touch the Forgejo measurement, and the review of that was fair: adding SQL toforgejo-storage-measure.shimproved what a human sees once they are already at the keyboard and did nothing about the fact that a human has to run it.The barrier was granularity, not access
Forgejo's data sits on a local-path PVC on the host, in the tree this server already walks and already totals at 123 GB.
scan_usage_profilereported immediate children with recursive totals and nothing below, so thedata/git/packagessplit, anddata/attachmentsinside it, were only reachable by aduper level._scan_pressure_childrenhas the same one-level shape. No permission was missing.Change
max_depthonUsageProfile, with children nested accordingly.k3s-storageandpod-ephemeralship at depth 3: claim ->data->attachments, and pod ->volumes-> volume type. The ceiling is fixed at 5 in code because each level multiplies the response, andlimitnow clips reported detail at every depth rather than only the top.Depth changes reporting, never the walk.
_scan_nodereuses the same flat_scan_treefor everything below the reported levels and absorbs its totals, so the numbers cannot drift between views:A regression test scans one tree at depth 1 and depth 3 and asserts identical bytes, apparent bytes, and entry counts. A depth that moved a byte would make both views untrustworthy, so that invariant is the thing worth pinning. A second assertion holds that a parent is never a bare sum of the children shown beneath it, since it still owns its own inode and its loose files.
Where this leaves the eight manual commands
Five fully unattended, one halved, two operator-only by design. The remaining half is attachment and package ownership - which repository, which release or issue, which age bucket - which lives only in PostgreSQL and still needs an attended
kubectl exec. Forgejo's API exposes per-release and per-issue assets, so an aosguard verb could reconstruct it withoutexec; that is agentic-os work and a separate issue.Verification
ward exec lint,ward exec test(47 passed, 1 new), andward exec precommitare clean on this branch rebased onto currentmain, after the docs reorganisation landed there.🤖 Generated with Claude Code