Repository navigation
fix(core): recheck cgroup tokens after exec and size simulated sweeps for load - #307
Merged
Merged
Conversation
Re-read an empty environment before classifying a settled cgroup member as foreign. Keep start-time checks across the token proof and signals. Cover exec completion before and after freeze, settled empty or foreign members, and PID reuse during the re-read. Closes #299
Use the product's 3000 ms TERM and 2000 ms KILL budgets for simulated cgroup cleanup. Keep all signal, refusal, and confirmed-cleanup assertions, and show the cleanup reason when the mid-exec signal test fails. With 96 busy loops and 30 concurrent simulated suites, failures fell from 15 of 30 runs to zero of 30 runs. Closes #300
Classify both environment reads with the same token and mid-exec checks. Treat a vanished member as gone and an unreadable or mid-exec member as unknown. Keep settled foreign and recycled member refusals. Add deterministic tests for vanished, unreadable, and repeated-exec reads before and after freeze, including a late mid-exec joiner. Retain the token-match, settled foreign, and PID-reuse regressions. Closes #299
Omit explicit cleanup options so simulated cgroup tests follow the product defaults. Replace the stale 500 ms comment with the full timeout. Closes #300
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Containment no longer refuses its own member when exec finishes between two reads, and the simulated sweep tests hold on a loaded host.
#299:
classifyCgroupEnvironmentread the environment and then the process stat in two steps. If exec finished between them, an owned member looked foreign and cleanup was refused. When the environment read was empty and stat shows exec has finished, classification now reads the environment again before it refuses. The existing start-time checks still pin the process across both reads. The second read is classified exactly like the first: a member that is gone settles, an unreadable or still mid-exec member is retried, and a settled foreign member is refused. Settled members with an empty, foreign or recycled identity are still refused.#300: the simulated cgroup tests gave the marker sweep 500 ms for TERM and for KILL. Under very high load that expired before two empty scans. The tests now inherit the product sweep budgets of 3 s and 2 s.
Closes #299
Closes #300
packages/core/test/containment-cgroup-sim.test.tscontainment-cgroup-sim.test.ts~/Artifacts/pickforge-batch4-2026-10-08/X-sol/report.md~/Artifacts/pickforge-batch4-2026-10-08/qa-X~/Artifacts/pickforge-batch4-2026-10-08/X-cov-r2.log