workspace: CoW fork from a materialize-once base cache#129
Merged
Conversation
k dispatch workers fork one bookmark near-free: materialize the snapshot once into a content-addressed base cache (base_cache.rs), then CoW-clone per worker (cow.rs; APFS clonefile / Linux FICLONE). --from-bookmark without --workspace now warms the base cache and leaves cwd untouched. Governance (brief): adds decision doc://pillbox/workspace-cow-fork (draft) + code refs; libkrun edits signed conforms in .brief/SIGNOFF; adds the brief CI gate.
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.
What
kdispatch workers fork one bookmark near-free: materialize the snapshot once into a content-addressed base cache (base_cache.rs), then CoW-clone per worker (cow.rs— APFSclonefile/ LinuxFICLONEreflink, degrading to a reported byte copy where reflink is unavailable).--from-bookmarkwithout--workspacenow warms the base cache and leavescwduntouched; the--workspaceand no-bookmark paths are unchanged.Governance (brief) — the process this PR exercises
First governed PR under
brief:doc://pillbox/workspace-cow-fork(status: draft) captures the fork mechanism, scoped viarelated_codetobase_cache.rs/cow.rs; both files point back with a// Context:ref.libkrun-is-the-backend,libkrun-env-fork-substrate,workspace-ingest-sovereignty— each signedconformsin.brief/SIGNOFF(implementation, no decision moved)..github/workflows/brief.ymlrunsbrief checkon this PR's diff and blocks if governed code changes without aconforms/amend-proposedsign-off.When the mechanism is firm: flip
workspace-cow-forktoactive+brief publish— from then its files are enforced.