Skip to main content

effective_backup_mover

Function effective_backup_mover 

Source
pub fn effective_backup_mover(
    snapshot: &SnapshotSpec,
    policy: &SnapshotPolicySpec,
) -> Option<MoverSpec>
Expand description

The mover configuration a backup run actually uses: Snapshot.spec.mover merged over the recipe’s SnapshotPolicy.spec.mover (#464).

Pure, so the controller, the admission webhook and the CLI all read one answer — the layer order can never fork between them. The repository’s moverDefaults is NOT folded in here: it enters underneath this result in resolve_mover, which every consumer already calls, giving the full ladder hardened ⊂ moverDefaults ⊂ inherited ⊂ policy.mover ⊂ snapshot.mover. MoverSpec::merge_over’s context merge is associative, so pre-folding the top two layers here is identical to a flat merge of all five.

None only when neither layer sets a mover at all, so a Snapshot that carries none resolves byte-identically to the pre-feature behavior.