diff --git a/src/internal/operations/backup.go b/src/internal/operations/backup.go index 6ecf7db85..e597e30da 100644 --- a/src/internal/operations/backup.go +++ b/src/internal/operations/backup.go @@ -169,6 +169,15 @@ func (op *BackupOperation) Run(ctx context.Context) (err error) { opStats.readErr = op.Errors.Err() } + // TODO: the consumer (sdk or cli) should run this, not operations. + recoverableCount := len(op.Errors.Errs()) + for i, err := range op.Errors.Errs() { + logger.Ctx(ctx). + With("error", err). + With(clues.InErr(err).Slice()...). + Errorf("doing backup: recoverable error %d of %d", i+1, recoverableCount) + } + // ----- // Persistence // ----- diff --git a/src/internal/operations/restore.go b/src/internal/operations/restore.go index e9f27869d..63565d852 100644 --- a/src/internal/operations/restore.go +++ b/src/internal/operations/restore.go @@ -156,6 +156,15 @@ func (op *RestoreOperation) Run(ctx context.Context) (restoreDetails *details.De opStats.readErr = op.Errors.Err() } + // TODO: the consumer (sdk or cli) should run this, not operations. + recoverableCount := len(op.Errors.Errs()) + for i, err := range op.Errors.Errs() { + logger.Ctx(ctx). + With("error", err). + With(clues.InErr(err).Slice()...). + Errorf("doing restore: recoverable error %d of %d", i+1, recoverableCount) + } + // ----- // Persistence // -----