Skip to main content

AuditSink

Trait AuditSink 

Source
pub trait AuditSink:
    Send
    + Sync
    + 'static {
    // Required method
    fn record<'life0, 'life1, 'async_trait>(
        &'life0 self,
        event: &'life1 AuditEvent,
    ) -> Pin<Box<dyn Future<Output = Result<(), CoolError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

Pluggable audit sink. Implementations fan audit events out to downstream systems (Kafka topics, Redis pubsub, HTTP webhooks, S3 buckets) for long-term retention or SIEM ingestion. The in-database audit table written by cratestack_sqlx remains the canonical record; sinks are best-effort projections.

Required Methods§

Source

fn record<'life0, 'life1, 'async_trait>( &'life0 self, event: &'life1 AuditEvent, ) -> Pin<Box<dyn Future<Output = Result<(), CoolError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Implementors§