Skip to content

Commit

Permalink
Merge branch 'raul/restart-with-recovery' of github.com:ConduitIO/con…
Browse files Browse the repository at this point in the history
…duit into raul/restart-with-recovery
  • Loading branch information
hariso committed Oct 3, 2024
2 parents 234c33a + d5dc4eb commit 94723c0
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions pkg/lifecycle/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -802,12 +802,14 @@ func (s *Service) runPipeline(ctx context.Context, rp *runnablePipeline) error {
if updateErr := s.pipelines.UpdateStatus(ctx, rp.pipeline.ID, pipeline.StatusDegraded, fmt.Sprintf("%+v", recoveryErr)); updateErr != nil {
return updateErr
}

// we assign it to err so it's returned and notified by the cleanup function
err = recoveryErr
} else {
// recovery was triggered didn't error, so no cleanup
// this is why we return nil to skip the cleanup below.
return nil
}
// recovery was triggered, so no cleanup
// (remove running pipeline, notify failure handlers, etc.)
// is needed
// this is why we return nil to skip the cleanup below.
return nil
}
}

Expand Down

0 comments on commit 94723c0

Please sign in to comment.