Separate request Root durability barriers from complete storage flushes

This commit is contained in:
2026-11-10 03:03:39 +08:00
parent 3ae18b1670
commit aa72f9e484
8 changed files with 138 additions and 27 deletions
+4
View File
@@ -221,3 +221,7 @@ test('bounded batches drain through settle without waiting for fake timers and h
assert.deepEqual(state.calls.map(([, request]) => request.operationIds.length), [64, 64, 2]);
assert.equal(state.ledger().getSnapshot().operations.get('op-129').phase, 'resolved'); state.scheduler.stop();
});
test('a fenced pump reports failed state publication without throwing or sending through the old identity',async()=>{
const state=setup({mutate(){throw Error('storage_leader_lost');}});state.scheduler.start();state.add('fenced');await tick();await state.scheduler.settle();assert.equal(state.calls.length,0);assert.equal(state.ledger().getSnapshot().requests.size,0);assert.equal(state.ledger().getSnapshot().operations.get('fenced').phase,'pending');assert.ok(state.errors.some(error=>error.message==='storage_leader_lost'));state.scheduler.stop();
});