diff --git a/docs/requirements/Component-SiteCallAudit.md b/docs/requirements/Component-SiteCallAudit.md index 491c800..d020d43 100644 --- a/docs/requirements/Component-SiteCallAudit.md +++ b/docs/requirements/Component-SiteCallAudit.md @@ -73,6 +73,14 @@ then **upsert-on-newer-status**. The lifecycle is monotonic, so status only advances and never regresses; at-least-once and out-of-order telemetry are therefore harmless. +From v1.x onward, the `CachedCallTelemetry` message additively carries the +`AuditEvent` content alongside the existing operational fields. Central's +`AuditLogIngestActor` (Audit Log #23) performs both the immutable `AuditLog` +insert and the `SiteCalls` upsert in a single transaction. Idempotency keys +remain `EventId` (for `AuditLog`) and `TrackedOperationId` (for `SiteCalls`). +See [Component-AuditLog.md](Component-AuditLog.md), Cached Operations — +Combined Telemetry, for the dual-write contract. + ## Reconciliation Because telemetry is best-effort, `SiteCallAuditActor` periodically — and on site @@ -119,6 +127,12 @@ configurable window (default 365 days), matching the `Notifications` purge. responses; sends Retry/Discard commands. - **Store-and-Forward Engine**: the site-side origin of cached-call telemetry and the executor of relayed Retry/Discard commands. +- **Audit Log (#23)**: shares the `CachedCallTelemetry` packet — each lifecycle + transition (`CachedEnqueued`, `CachedAttempt`, `CachedTerminal`) carries an + `AuditEvent` alongside the operational fields, and central's + `AuditLogIngestActor` performs the `AuditLog` insert and the `SiteCalls` + upsert in a single transaction (see [Component-AuditLog.md](Component-AuditLog.md), + Cached Operations — Combined Telemetry). - **Commons**: `TrackedOperationId`, status enum, telemetry message contracts. ## Interactions