Expand description
Per-page audit log.
Every meaningful action on a page (publish, edit, move, copy, alias create, restore, lock, unlock, force-unlock, workflow submit / approve / reject / cancel, comment new / resolved / reopened) lands a row. Revisions answer “what changed”; log entries answer “who did what, when”.
Best-effort: a log-write failure is logged + swallowed; the underlying action commits regardless. Compliance > availability ordering — but in our case the action is the source of truth and the log is observability.
Structs§
Constants§
- ACTION_
ALIAS_ CREATE - ACTION_
COMMENT_ NEW - ACTION_
COMMENT_ REOPEN - ACTION_
COMMENT_ RESOLVE - ACTION_
COPY - ACTION_
DELETE - ACTION_
EDIT - ACTION_
FORCE_ UNLOCK - ACTION_
LOCK - ACTION_
MOVE - ACTION_
PUBLISH - ACTION_
RESTORE - ACTION_
UNLOCK - ACTION_
UNPUBLISH - ACTION_
WORKFLOW_ APPROVE - ACTION_
WORKFLOW_ CANCEL - ACTION_
WORKFLOW_ REJECT - ACTION_
WORKFLOW_ SUBMIT
Functions§
- for_
page - Every log entry for a page, newest first. Bounded by
limitso the history tab doesn’t render thousands of rows; passNoneto return everything (CSV export uses that). - record
- Insert a log entry. Best-effort; on failure logs + returns Ok so the call-site doesn’t have to special-case audit-write errors.
- record_
or_ warn - One-shot fire-and-forget convenience: records a log entry and swallows + logs any error. Use this at fire-sites where audit failure should never block the underlying action.