Skip to main content

AuditWriter

Trait AuditWriter 

Source
pub trait AuditWriter: Send + Sync {
    // Required method
    fn append(
        &self,
        event: &AuditEvent,
    ) -> Result<(), Box<dyn Error + Sync + Send>>;
}
Expand description

Trait for appending audit events to a log.

Implementations must be Send + Sync for use across async boundaries. The trait is object-safe to allow dyn AuditWriter.

Required Methods§

Source

fn append(&self, event: &AuditEvent) -> Result<(), Box<dyn Error + Sync + Send>>

Append a single event to the audit log.

Implementors§