Designs tab: Deleting a design doesn't actually delete [Backend 3: Services]

About

This is one of four issues for the backend implementation of #38048.

Tasks

  1. Rename existing DeleteDesignsService to ArchiveDesignsService
  2. Add new DeleteDesignsService that hard deletes designs by:
    • Setting the property migrated in #227118)
    • Dereferences the LFS object in a way which can be cleaned up later (see below).

Deferencing the LFS object

At time of writing there is a rake task that can be run by admins that will "clean up" orphaned LFS Objects. This is scheduled to be run automatically in a near-milestone #223621 (closed).

The class responsible is OrphanLfsFileReferences.

The class currently cannot work for design repositories. See #229735 (closed).

However, the DeleteDesignsService added in this release should set up a deleted design in a way that will anticipate OrphanLfsFileReferences being able to work with design repositories in future #229735 (closed).

Edited by Luke Duncalfe