Skip bridge status worker for pipelines failed at creation

What does this MR do and why?

When a downstream pipeline for a strategy: depend or mirror bridge fails during creation (for example a config error), it is persisted as failed. That first save already matched the completed-status hook and enqueued PipelineBridgeStatusWorker, which raced with CreateDownstreamPipelineService. When the worker won, the bridge was failed with unknown_failure, the service's drop! raised InvalidTransition, and the downstream error message was never stored on the bridge.

The creating service is responsible for the bridge status in that case, so only schedule the worker for pipelines that were already persisted.

References

Related to #516054

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports

Loading
Loading