Create a service to marks many packages for destruction
Context
This work is part of two epics. Package Registry cleanup policies MVC (&5152 - closed) because it is a key step in creating the next iteration of package-cleanup policies, which will allow users to programmatically delete packages.
It is also a part of Bulk delete packages and package assets from th... (&8022 - closed) because it's required to update the user interface to allow users to multi-select delete packages from the GitLab application.
Problem to solve
In order to bulk delete packages, we need a service that can first mark n
items for destruction, so they can be deleted later from object storage.
For example, check out the service for package assets.
Proposal
Create a service for the bulk deletion of packages to unblock phase 2 of the cleanup policies and bulk deletion from the UI.
Batch size
- For assets, we chose 500 as the batch size. Maybe the same would work for packages?