Skip to content

Use result of destroying container repositories when destroying projects

Adie (she/her) requested to merge update-proj-destroy-service into master

What does this MR do and why?

Closes #385171 (closed)

This MR updates ContainerRepository::DestroyService to return a hash with the key status that will contain success or error depending if the operation succeeded or not. This return value is then used in Project::DestroyService to determine if the operation has already failed with the deletion of container repositories.

Today, we do not check if the deletion of container repositories failed or succeeded so it can happen that a project is successfully destroyed but there are remaining container repositories.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

How to set up and validate locally

  1. Create a project
  2. Add container repositories to the project
  3. Delete the project
  4. All container repositories should be deleted
  5. If there's an error in deleting container repositories, project deletion should also fail.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Adie (she/her)

Merge request reports

Loading