[Feature] Govern file restore, retention, legal hold, purge, and blob garbage collection #38

Closed
opened 2026-07-21 16:48:03 +02:00 by zemion · 1 comment
Owner

Outcome

Files has an explicit lifecycle from soft deletion through restore or authorized purge, while retention, legal hold, shared references, and Campaign evidence prevent premature byte destruction.

Acceptance

  • Restore soft-deleted files/folders/spaces without losing version or provenance evidence.
  • Resolve effective retention and legal-hold blockers before purge.
  • Preview and execute bounded, idempotent purge actions with separate authority and audit.
  • Recompute/reference-check blob use before garbage collection; never delete bytes still referenced by another asset/version/evidence record.
  • Coordinate with the database/blob integrity reconciliation work in #36.
  • Document backup interactions, erasure limitations, and operator recovery.
  • Cover concurrent references, interrupted purge, repeated requests, and rollback/correction paths.
## Outcome Files has an explicit lifecycle from soft deletion through restore or authorized purge, while retention, legal hold, shared references, and Campaign evidence prevent premature byte destruction. ## Acceptance - Restore soft-deleted files/folders/spaces without losing version or provenance evidence. - Resolve effective retention and legal-hold blockers before purge. - Preview and execute bounded, idempotent purge actions with separate authority and audit. - Recompute/reference-check blob use before garbage collection; never delete bytes still referenced by another asset/version/evidence record. - Coordinate with the database/blob integrity reconciliation work in #36. - Document backup interactions, erasure limitations, and operator recovery. - Cover concurrent references, interrupted purge, repeated requests, and rollback/correction paths.
Author
Owner

Implemented and verified in govoplan-files@6c3cf1c; operator recovery documentation is extended in govoplan-ops@399e1f8.

The slice adds version-preserving restore, explicit retention/legal-hold revisioning, bounded purge preview and execution, separate purge authority, Campaign/Form evidence and active-share blockers, durable irreversible recovery operations, and reference-rechecked blob garbage collection with shared lease fencing and verified outcomes.

Verification: Files Ruff and 154 tests passed, covering concurrency, retained/held/shared/evidence blockers, idempotency, interruption/retry, tamper/conflict behavior, and storage failure handling. Manifest validation and the full cross-module focused gate passed.

Implemented and verified in `govoplan-files@6c3cf1c`; operator recovery documentation is extended in `govoplan-ops@399e1f8`. The slice adds version-preserving restore, explicit retention/legal-hold revisioning, bounded purge preview and execution, separate purge authority, Campaign/Form evidence and active-share blockers, durable irreversible recovery operations, and reference-rechecked blob garbage collection with shared lease fencing and verified outcomes. Verification: Files Ruff and 154 tests passed, covering concurrency, retained/held/shared/evidence blockers, idempotency, interruption/retry, tamper/conflict behavior, and storage failure handling. Manifest validation and the full cross-module focused gate passed.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: GovOPlaN/govoplan-files#38