Reconcile external payments after restoring a canister snapshot
A snapshot can restore a canister's execution state while another canister retains everything that happened after the snapshot.
Trace one invoice across the restore
Take the example of an invoice awaiting payment when snapshot S was taken. The service later paid the invoice and recorded ledger block 843. Loading S removes the local completion marker. Keep the snapshot identifier together with an external journal of transfers so that operators can find this discrepancy.
snapshot S: local invoice = pending
ledger block 843: transfer accepted
load S: local invoice = pending
Resume the payout worker
Before releasing pending invoices to the worker, verify the recipient, amount and ledger record against the journal. Mark the reconciled invoice complete using the application's recovery procedure. The snapshot alone cannot establish which external operations finished during the interval.