docs(adr): defer soft delete and the trash past GA
Summary
- Problem: Soft delete, restore, the trash and purge are deferred past GA (unified-artifact-management!204), so a delete is permanent at GA. ADR-010, S20-A, S17, S35 and monolith/S11 still say the trash ships at GA, and ADR-009 still says GA drops the
destructiveparameter, so anyone building or reviewing a delete path reads the wrong release. - Decision: Closed beta and GA keep permanent delete. Soft delete, restore, the trash and expiration still ship together as one feature, after GA. The repository
DELETEkeeps its requireddestructiveparameter for all of/api/v1: its two values guard every repository delete, whether it is permanent or, after GA, goes to the trash. The design itself does not change. - Who it affects: engineers working on delete paths, the purger and the Trash, in AR and the monolith. No code, API, schema or user-visible behavior changes.
- Downside: ADR-009 loses its rule that a still-sent
destructivegets an explicit rejection naming the trash. That rule only applied if GA removed the parameter. A later API version that drops it has to set its own rule.
What changed
No line this MR adds names a release, as !4026 (merged) asks: the ADRs, specs and dev doc say "until the trash ships" or "once the trash ships" instead. Lines that mention only closed beta stay, because closed beta has shipped.
- ADR-010: every line that dated soft delete or the trash to GA, or permanent delete to closed beta, now says the order: the context table, Release Phasing, Deletion Precedence, constraints 1 and 2, Soft Delete, and the API-First Soft Delete alternative. Soft Delete Expiry drops its line on who sets the window length. Release Phasing's scoping sentence now covers only what the sections below say about soft delete, restore and the trash, so default retention, garbage collection and the audit and disposal constraints still bind GA. The soft-delete phase of Subscription Expiration is unchanged, because B3 owns it. Constraint 2 names the three deletion triggers constraint 1 lists, so it doesn't cover that phase.
- ADR-009: Repository Deletion keeps the
destructiveparameter for all of/api/v1instead of dropping it at GA, because its two values guard every repository delete, whether it is permanent or goes to the trash. Neither that line nor the ADR-010 reference names a release. - S20-A: the Forward compatibility table and its notes say what the trash does, and the
destructiverow keeps the parameter for all of/api/v1. The summary, the ADR-010 reference lines and every body line that gave GA the trash listing, the container columns, the window flip or the restore surface now say the trash. The Resolutions keep their dates and links, and only their clauses that are now false say "until the trash ships" or the trash. The first one also cites unified-artifact-management!204 for the deferral, and the billing one records that trashed artifacts bill until they are purged. - S17: the S20 dependency row says the soft-delete model replaces the hard delete, without a release, and the
destructiveresolution says the API keeps the parameter for all of/api/v1. Phase 4's window lines, the container columns and the trash listing index say the trash instead of GA. Phase 4's soft-delete resolution says tombstones on a zero window implement the contract until the trash ships, and that ADR-010 targets soft delete rather than mandating it now. - monolith/S11: the summary and the ADR-010 reference no longer say the trash ships at GA. Where "at GA" meant the Trash's first release, it now says "in the Trash's first release" or "later", since S20-A uses "the first release" for closed beta. The GraphQL
experimentuntil GA lines are unchanged. - S35 and the database query patterns doc: their one line each that dated the trash or restore to GA now say the trash.
With the ADR-009 and S20-A changes, this MR also covers the doc part of A1's destructive bullet on the work item, and the S20-A billing line covers B2. gitlab#630799 is updated to match: after GA, and trashed items bill until purged.
Left as they are:
- S20-A's "survives to GA", which is still true.
- User docs, the API description and UI copy, which A3 covers once product confirms the wording.
ADR-026: its Trash rows also say GA, but ADR-026 is internal, so its text can't go in this public repository. It is amended in a separate internal handbook MR: https://gitlab.com/gitlab-com/content-sites/internal-handbook/-/merge_requests/9320 (internal).
After this merges, the weekly ADR handbook sync copies ADR-009 and ADR-010 to the handbook.
Checklist
- Reach: every feature that deletes data (repository, artifact, bulk and cascade deletes, the purger), the repository
DELETEcontract, and the Trash work in AR and the monolith. It changes when the trash ships and how longdestructivelives, not how either works. - Least sure: dropping ADR-009's explicit-rejection rule. If we want a later API version to name a recovery path when a client still sends
destructive, that rule needs to come back when that version is designed. - Agreement: the deferral was decided on 2026-11-09 and recorded in unified-artifact-management!204, the trash itself is gitlab#630799, and keeping
destructivefor all of v1 is A1 on #1892. The Engineering Lead approves the ADR-009 and ADR-010 changes, and a Staff+ engineer approves the spec changes. - Durability: the ADRs name no release, so moving the trash again needs no ADR change. Revisit ADR-009 when a later API version is planned.
Overlap: !3831 (merged) merged first. This branch is rebased onto it and keeps its cache-eviction sentences in ADR-010's Deletion Precedence and constraint 1. !3735 (merged) and !3961 (merged) touch S17 and S20-A elsewhere, and this branch adds no conflict with either. No open MR edits ADR-009.
How to set up and validate locally
Docs only, so nothing runs against a service. These are the checks that apply.
Step 1: run the hooks on the changed files
pre-commit run --files docs/adr/009_api_design.md docs/adr/010_data_retention.md docs/specs/S20-a-lifecycle-closed-beta.md docs/specs/S17-rest-management-api.md docs/specs/monolith/S11-soft-deletion-trash-and-restore.md docs/specs/S35-remote-cache-retention.md docs/dev/database-query-patterns.mdOutput (✅ )
markdownlint-cli2........................................................Passed
lychee...................................................................Passed
vale.....................................................................Passed
gitleaks | common-ci-tasks...............................................Passed
editorconfig | common-ci-tasks...........................................Passed
ADR index................................................................Passed
document word limits.....................................................Passed
no AGENTS.md or guardrail citations......................................Passedgitlint passed on every commit.
Step 2: check that no over-limit spec grew
S20-A and S17 are over the 15,000-word spec limit, so they may shrink but not grow.
scripts/ci/check-doc-size.sh --base origin/mainOutput (✅ )
No changed document is over its word limit.S20-A shrinks from 29,612 to 29,470 words, and S17 from 57,535 to 57,532.
Step 3: look for "trash ships at GA" or "GA drops destructive" phrasing left in the changed files
git grep -nE "(ships?|shipping) (together )?at GA|[Ff]rom GA|GA.s (trash|expiry|recovery)|GA sets|delete at GA|(not open|Restore all|policy name) at GA|drops the parameter|removed at GA|GA (trash|restore|adds|raises|flip|soft-delete)|wait for GA|stay at GA|to GA\.|GA-only|GA-side|open GA decision|removal at GA" -- docs/adr/009_api_design.md docs/adr/010_data_retention.md docs/specs/S20-a-lifecycle-closed-beta.md docs/specs/S17-rest-management-api.md docs/specs/monolith/S11-soft-deletion-trash-and-restore.md docs/specs/S35-remote-cache-retention.md docs/dev/database-query-patterns.mdOutput (✅ )
50 matches on origin/main, 1 on this branch:
docs/specs/S20-a-lifecycle-closed-beta.md:761:What is left here is two kinds of site, and the arrangement is the one that survives to GA.It is still true, and this MR doesn't touch it. No line this MR adds names GA, and ADR-009 and ADR-010 have no "GA" or "closed beta" left at all.
Evidence
N/A: docs only. No client, GraphQL or UI change.
Related to https://gitlab.com/gitlab-org/ops/artifact-registry/-/work_items/1892