Skip to content

Graphorin API reference v0.7.0


Graphorin API reference / @graphorin/server / commentary

commentary

Delivery-layer commentary-phase trace sanitization for @graphorin/server.

Interfaces

InterfaceDescription
CommentaryAuditSinkA commentary sink that also exposes a drain() so callers (and tests) can await any in-flight audit writes.
LateBoundCommentarySinkA DeliveryCommentarySink whose real target is installed later. The WS dispatcher is created before the audit DB opens (IP-21); the server hands it this forwarding sink and calls LateBoundCommentarySink.bind once the audit-writing sink exists. Decisions emitted before binding are dropped - the dispatcher only sanitizes once it is live (after start(), by which point the audit DB, if configured, has opened and bound).

Variables

VariableDescription
COMMENTARY_AUDIT_ACTIONAudit action recorded for a delivery-commentary sanitization decision.

Functions

FunctionDescription
bridgeCommentaryToAuditBuild a commentary sink that appends each sanitization decision to the audit log. Writes serialise through appendAudit so concurrent decisions never race on seq; a failed write is isolated from the wire - onWriteError (default: a console warning) runs instead of throwing.
commentaryDecisionToAuditInputTranslate a sanitizer decision into an audit entry. The digests + matched pattern bucket land in metadata; raw payloads never do (the sanitizer only ever exposes SHA-256s of the before/after bodies).
createLateBoundCommentarySink-

References

createDeliveryCommentarySanitizer

Re-exports createDeliveryCommentarySanitizer


DEFAULT_APPLY_TO_EVENTS

Re-exports DEFAULT_APPLY_TO_EVENTS


DEFAULT_DELIVERY_COMMENTARY_PATTERNS

Re-exports DEFAULT_DELIVERY_COMMENTARY_PATTERNS


DeliveryCommentaryConfig

Re-exports DeliveryCommentaryConfig


DeliveryCommentaryDecision

Re-exports DeliveryCommentaryDecision


DeliveryCommentaryPattern

Re-exports DeliveryCommentaryPattern


DeliveryCommentaryPolicy

Re-exports DeliveryCommentaryPolicy


DeliveryCommentaryReason

Re-exports DeliveryCommentaryReason


DeliveryCommentarySanitizer

Re-exports DeliveryCommentarySanitizer


DeliveryCommentarySink

Re-exports DeliveryCommentarySink


DeliveryCommentaryTransport

Re-exports DeliveryCommentaryTransport