Repository navigation
This release adds a memory fuse (memFuse) to cpdaemon: it stops cpworker, or refuses to start it, when the host is short of memory, so a capture ring sized for the configured memory limit can no longer push a small VM into a system-wide OOM.
⚠️ Upgrade Notes
-
memFuse is controlled by CPM. The fuse is armed only when the CPM strategy response carries
memFuseEnabled: true. With a CPM that doesn't send the switch, the fuse stays disabled and cpdaemon behaves as in 0.9.5. -
A fused worker stays stopped until an administrator clears the fuse in CPM. While fused, cpdaemon ignores strategies and doesn't restart cpworker; a strategy with
memFused: falseclears it and runs the startup check again. -
New config keys
cpm.worker.mem_fuse.*(seeexamples/cpdaemon/template.json):Key Default Meaning check_interval1sHow often the runtime check reads MemAvailablefail_threshold3Consecutive low readings before the fuse trips min_available_mb256Memory (MB) kept free for the host. A runtime reading below it counts as a hit; the startup check requires this much left after the ring is allocated
✨ Features
cpdaemon
-
memFuse. cpdaemon checks
/proc/meminfoMemAvailableand fuses in two places:- Before a capture ring is allocated: on a start (every task) or a reload (only tasks whose fingerprint changed), it refuses when
MemAvailable< ring about to open × 2 +min_available_mb. A strategy change that keeps every task (e.g.cpuLimit,syncInterval) allocates nothing and isn't checked. - While cpworker runs: it trips after
fail_thresholdconsecutive readings belowmin_available_mb.
On a trip, cpdaemon kills cpworker with SIGKILL, so the ring is freed at once instead of after the pipeline drains, and reports
memFuseto CPM immediately.memFuseis also included in every metrics report. - Before a capture ring is allocated: on a start (every task) or a reload (only tasks whose fingerprint changed), it refuses when
🔧 CI / Tests
- The
timeout_ms > 0integration tests use an 8 MB capture buffer. (#318) golang.org/x/netv0.55.0 in the cpworker integration test modules, which clears Dependabot alerts for CVE-2026-25680. The vulnerablex/net/htmlcode was never built, and the shipped binaries are unaffected. (#319)
⚠️ Known Issues
- With
cpm.worker.mem_fuse.min_available_mbset to0, the runtime check never hits: cpworker is not stopped when memory runs out, and only the startup check applies. Keep the default256or set a value greater than0. This will be fixed in a later release.
Full Changelog: v0.9.5...v0.9.6