fix(memiavl): stop leaking a pond worker-pool goroutine on every Load #141
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.32) × (1 − Review Confidence (0.57)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.32 · 118 lines diff across 1 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Shallow Review Depth
shallow_review_depth
0.289
Diff Size
diff_size
0.286
Real PR Conversation Timeline
1 comments
"Review active on #141"
general
weight: 0.35
thomas-nguy
What
memiavl no longer keeps a pond worker pool on the
DB. Each snapshot write creates its own pool and stops it before returning; theDBkeeps only the writer limit. Split out of #103.Issue
Every
Loadcreated a pool that was never stopped, leaking pond's purger goroutine. rootmulti does a read-onlyLoadper historical-height query, so an RPC node's goroutine count grows with that traffic. Stopping a shared pool inClose(#103's approach) would panic a copy that writes after its source closes; a pool per write avoids that.Solution
writeSnapshotWithLimitruns the write, thenStopAndWaits its pool.copy()carries the limit, so the background rewrite keeps its worker count.SnapshotWriterLimitnow applies per write, not across a DB and its copies.Loadcreates no pool.