Move pipelines page to GraphQL - Part 8
What does this MR do and why?
Part one: !206072 (merged)
Part two: !207467 (merged)
Part three: !208865 (merged)
Part four: !209348 (merged)
Part five: !210021 (merged)
Part six: !209716 (merged)
Part seven: !210372 (merged)
Part eight: YOU ARE HERE
Goal: Move Build > Pipelines to use GraphQL as the SSOT for data. In part eight we add the subscription implemented in !210777 (merged) to provide realtime pipeline state/statuses to our users.
References
Screenshots or screen recordings
How to set up and validate locally
- First visit
Build > Pipelinesand ensure existing feature works as expected. - Next enable
Feature.enable(:pipelines_page_graphql)&&Feature.enable(:ci_pipeline_statuses_updated_subscription)feature flags - Visit
Build > Pipelinesagain - Trigger changes to pipelines (run, cancel, retry)
- Ensure statuses reflect true state with subscriptions
Helpful rails console commands
If you don't want to trigger changes in the UI, you can also do this per pipeline in the rails console
pipeline = Ci::Pipeline.find(YOUR_ID)
# Test multiple status changes
pipeline.run!
# Check subscription fired with "running"
pipeline.succeed!
# Check subscription fired with "success"
pipeline.run!
# Check subscription fired again with "running"
pipeline.drop!
# Check subscription fired with "failed"
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.
Related to #223264
Edited by Payton Burdette
