ADR-0038: Periodic-review realization — derived due date, policy-gated confirmation¶
- Status: accepted
- Date: 2026-07-02
- Deciders: Nicolas Burri
- Refines: ADR-0015 (the model), ADR-0030 (the policy this extends), ADR-0037 (the sweep this joins)
- Refined by: ADR-0039 (the sweep & periodic-review contract as shipped — grants, guards, addressing)
Context¶
ADR-0015 fixed the periodic-review/effectivity model; realizing it (REQ-EFF-001..008 minus the e-sig hook 005) leaves three forks, decided 2026-07-02.
Decision¶
- Next-review-due is DERIVED, never stored:
anchor + interval, where anchor = the later of the current effective version'seffective_fromand the document's last confirmed periodic review date; interval = the per-document override or the document type's default. Interval config changes therefore apply retroactively by construction. Rejected: a storednext_review_duecolumn (second source of truth requiring backfills). - Confirmation is gated by the review policy: a
PERIODIC_REVIEWentry in the existing transition-permission table — configured roles may confirm; the unconfigured default is any scope member (consistent with every other transition, ADR-0030). The future e-sig requirement (REQ-EFF-005) attaches to the same policy. Rejected: a new closed-set permission. - Slice scope — the full REQ-EFF group (Nicolas chose all three parts):
- Core:
review_intervalondocument_type+ override ondocument; aperiodic_reviewrecord (document, reviewer, date, outcome CONFIRMED/REVISION_INITIATED, comment) — scope-keyed under RLS, append-only like approvals; confirm endpoint; "revision initiated" is recorded and then delegates to the existing new-version flow;PERIODIC_REVIEW_DUEdetection as one more statement in the ADR-0037 sweep (idempotent: skip while an OPEN task exists; the task resolves on confirm/new-version); inbox integration; audit events (REQ-EFF-008). - Validity:
document.valid_until+VALIDITY_EXPIREDsurfacing in the same sweep — flag-and-escalate only, never auto-revoke (REQ-EFF-007). Needs a task-type CHECK extension. - Future-dated effectivity: release accepts an optional future
effective_from(REQ-EFF-001); the effective version stays the derived rule of REQ-EFF-002.
Consequences¶
- New migration: type/document interval columns,
valid_until,periodic_reviewtable (+ RLS, append-only grants), sweep v2, task-type CHECK extension. - The sweep gains its first detection queries (due/expiry) beyond task-state reminders — the ADR-0037 mechanism is reused unchanged.
- REQ-EFF-005 (e-sig on review) stays deferred with the e-signature scope (no e-sig in MVP).