Commit graph Aetheria/docs/cultcache-migration-cut.md
Author SHA1 Message Date
Meta Vens
b0cb0fa7dc Keep directory stores merging under an unconditional commit
Operator chose option A: a flush or unconditional commit on a directory store
lands its changed pages onto the current manifest, so other writers' records
survive, while a single-file store stays last-writer-wins. Also records that an
attached store shares its cache's gate, which is how Cut 3 fixed the lock order.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 18:55:27 +02:00
Meta Vens
edb6703d3b Record Cut 3's concurrency and commit decisions
Operator chose option A on all three questions Soul raised: one lock order
(cache, then store) with store I/O blocking that cache's readers; an
unconditional Commit is last-writer-wins like a flush; a store that fails to
hydrate on open throws and is never overwritten. Also records one key per
store, load-only OnUpdate, missing-file dirtiness, the late-route fixture,
TryGet kept for AquaSynth, the scoped SemaphoreSlim check, and the corrected
size target for CultCache.cs.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 18:32:58 +02:00
Meta Vens
d311901dbc Decide store overwrite for Cut 3: the consumer removes and rewrites
Operator chose option A. Opening hydrates; a consumer that wants a fresh store
removes the records it does not keep, upserts, and flushes, and the atomic
snapshot replace does the rest. No CultLib API is added and PullOnOpen goes in
Cut 3. The two AquaSynth single-document writers adopt that form; the
File.Exists-style setters in AquaSynth and Mimir just drop the property.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 17:25:30 +02:00
Meta Vens
e4a9cb4113 Record Cut 2's real behavior changes and restore durability coverage in Cut 3
Cut 2 was not purely subtraction: load-time admission failures now propagate,
a store attached to a second cache replaces the first cache's callbacks, a
missing manifest empties the store on the next flush, and a v1 snapshot opened
as a directory store throws. The code still keeps atomic replace, manifest
ordering, content-addressed pages and both leases, but the tests for them left
with the stage probes. Cut 3 now restores them with real file locks, makes load
all-or-nothing, refuses shared stores, settles the legacy catalog resolver, and
keeps CultNet from publishing before a batch commits. The managed document is
recorded as parked with SoA.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 17:13:09 +02:00
Meta Vens
8a889ee494 Amend Cut 2 from Hands' findings; open the overwrite question for Cut 3
OpenAsync keeps pulling until attach hydrates in Cut 3. CultCache.FlushAsync
keeps its dead soft parameter for Studio's reflection until Cut 6. Loaded and
Unloaded are protected internal; PullSelected goes with the directory store;
a missing directory manifest is an empty store; doc comments go from all eight
files. PullOnOpen has AquaSynth and Mimir setters that mean overwrite without
loading, so Cut 3 must decide who owns replacing a store before deleting it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 16:34:02 +02:00
Meta Vens
1643027851 Amend the cut map from Cut 1's Soul review
Cut 3 rewrites the Cut 1 fixture that attaches a second untyped store and
retires the reflective IsGlobal hack. Cut 4 makes the generator discover
inherited members like the reflective registry, so derived documents hash one
schema id in both builds, and requires [Key] on persisted document members.
Corrects sibling attach wording, the C# commit status, and a deleted doc target.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 16:11:50 +02:00
Meta Vens
040e50b249 Finish the compare-exchange fold-in; mark the race probe failed
The two-process race probe (P7) spawned recursively and produced no trustworthy
result, so conditional commit's lock behavior is proven by Cut 3's tests, which
now require guarded child launches (explicit host, role chosen by environment,
fail if a child would spawn) or in-process concurrent file handles. The fork bomb
is recorded among the risks. Compare-exchange leaves the follow-ups.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 15:52:17 +02:00
Meta Vens
365e8cd781 Fold compare-exchange into the atomic commit cut (in progress)
Saved mid-pass after a workstation crash: per-entry Expect and ExpectUnchanged
on the one-store batch, TryCommit, a lock sidecar for the single-file store,
the last-writer-wins flush contract, the race tests and probe P7, and full
CultLib\packages paths for sibling runtimes. The Imagination pass is finishing
the rest.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 15:37:25 +02:00
Meta Vens
80018f9730 Reshape the CultCache cut map: parked SoA, fixed routes, owned generator, atomic commit
Second and third Imagination passes, probe-backed. Globals get lifecycle owners
and the cache invents none; routing admits a record's home once and refuses
later routes over admitted types; mirrors go in every runtime; subtraction is
separated from behavior. SoA is parked at a tag with its intent recorded.
The MessagePack generator is contained in CultLib's own package reference.
Atomic multi-record commit stays as an explicit one-store batch replacing the
ambient transaction machinery. AetheriaEve is removed from all evidence.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 14:28:26 +02:00
Meta Vens
82c1e72e2b Map the CultCache migration cut
The Imagination pass over cultcache-migration-target.md: answers to its eight
questions with evidence from CultLib and its canonical packages, the CultLib
store-routing authority map, the wire-parity plan, ten sequenced cuts with
failing-first tests, negative checks and build budgets, a subtraction ledger,
and rejected paths. Two corrections on review: Cut 0 is already done
(6bd3e176, 560779a4), and Cut 7 adds an LFS rule for .cc before committing
the catalog.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-12 23:40:17 +02:00