Prevent object storage orphans when destroying project
requested to merge mo-follow-up-from-fix-cross-modification-table-for-groupdestroyworker into master
Ref: #352902 (closed)
What does this MR do and why?
This MR sets dependent: :restrict_with_error to models having object storage records and associated to a project:
Ci::BuildTraceChunk
Ci::JobArtifact
Ci::PipelineArtifact
Ci::SecureFile
This will prevent having orphan records if those child records are not deleted before the project gets destroyed.
Those objects are currently destroyed in our Projects::DestroyService before destroying the project so we should not have any orphan records.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Max Orefice