S20: Lifecycle management
## Summary
Umbrella epic for **S20 Lifecycle management** in the Artifact Registry Go service: soft-delete, restore, permanent purge, expiration, quarantine, and trash listing for artifacts and repositories.
Scope was split by [!710](https://gitlab.com/gitlab-org/ops/artifact-registry/-/merge_requests/710): garbage collection is now **S28** and cleanup policies **S29**. This epic tracks the S20 lifecycle scope only.
## Scope
- Soft-delete **cascade rules** across per-format tables.
- **Restoration** semantics — no blind restore against a live row at the same coordinate.
- **Permanent purge** of soft-deleted rows.
- **Expiration** / recovery-window enforcement (ADR-010).
- **Quarantine**.
- **Trash listing**.
- **Reconciler trigger sites** — when the format reconcilers run (e.g. `MetadataReconciler.Reconcile` from S10); the reconciler logic stays in the format spec.
## Out of scope
- Hard-delete garbage collection → **S28**.
- Cleanup policies → **S29**.
## Downstream consumers
- **S17 [#197](https://gitlab.com/gitlab-org/ops/artifact-registry/-/work_items/197)** — repository soft-delete model, gated on S20's async artifact-and-blob cascade + recovery-window enforcement.
- **S22** — storage accounting; soft-delete/restore/purge are the trigger sites for logical counter events (`repositories.size_bytes`, `artifacts_count`). Physical/dedup size changes come from S28, not soft-delete.
- **S13** — reserves background jobs for cache lifecycle (S20, S28).
## References
- Spec (to be written): `docs/specs/S20-lifecycle-management.md`
- [ADR-007 Database schema](https://handbook.gitlab.com/handbook/engineering/architecture/design-documents/artifact_registry/decisions/007_database_schema/), ADR-010 Data Retention
- Split MR: [!710](https://gitlab.com/gitlab-org/ops/artifact-registry/-/merge_requests/710)
## Child items
- [#55](https://gitlab.com/gitlab-org/ops/artifact-registry/-/work_items/55) — S20: Lifecycle management foundational spec
epic