Skip to content

Display diffs for every component in incident rollback comment

Reuben Pereira requested to merge rp/incident-component-diffs into master

What does this MR do and why?

Describe in detail what your merge request does and why.

Similar to the component diffs that are displayed on "deployment started" notifications in Slack, display component diffs in the rollback comment added to incident issues.

Rollback::Presenter is the class that decides the format of the comment. Metadata::Presenter is the class that generates the component diff strings as an array of strings.

Rollback::Presenter is called in two classes, Promotion::Checks::IncidentRollback and AutoDeploy::RollbackCheck.

  • Promotion::Checks::IncidentRollback adds a comment to incident issues.
  • AutoDeploy::RollbackCheck responds to the /chatops run rollback check Slack command.

This MR:

  • Modifies Rollback::Presenter to use the output of Metadata::Presenter to display the component diffs in the correct format for Slack and Markdown.
  • Reverts !1964 (merged) since we don't need to put the Slack link in the incident comment anymore.

https://gitlab.com/gitlab-com/gl-infra/reliability/-/issues/15980

Author Check-list

  • Has documentation been updated?
Edited by Mayra Cabrera

Merge request reports