Documentation
¶
Overview ¶
Package auditoutbox owns the SDK-private lease and fence mechanics for the public audit package's per-app table. Module authors use audit.Record and ms.DrainAudit; exposing this layer would invite competing drainers.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrLeaseLost = errors.New("mirrorstack/audit: outbox lease was fenced")
ErrLeaseLost means a newer claim owns the row. A stale worker must not acknowledge, retry, or quarantine it.
Functions ¶
func Acknowledge ¶
Acknowledge marks a lease delivered only when its rotating token still owns the row.
func Quarantine ¶
Quarantine makes a permanently invalid or exhausted row terminal without deleting the evidence an operator needs to inspect it.
Types ¶
type Delivery ¶
type Delivery struct {
ID int64
EventID string
OccurredAt time.Time
SubjectKind string
SubjectID string
Action string
Details json.RawMessage
Proof []byte
Attempts int
LeaseToken string
}
Delivery is one privately-provenanced outbox row leased for forwarding. Proof is exact canonical invocation JSON and must only be placed back into the platform invocation header; it must never be logged or exposed to module code.