Skip to main content

snapshot_decision

Function snapshot_decision 

Source
pub(super) fn snapshot_decision(
    load: Result<(u64, i64), &Error>,
    journal: Option<JournalView>,
) -> SnapshotDecision
Expand description

Pure decision: snapshot-load outcome × live-journal view → restore or full scan. The load result carries only the persisted checkpoint; the index itself never enters the decision.

journal is None when FSCTL_QUERY failed or was skipped because the load already failed (the worker never queries in that case — a failed load must not spend an FSCTL). The load arm is matched first, so the two None meanings cannot mix.