Skip to main content

LogFormatter

Trait LogFormatter 

Source
pub trait LogFormatter: Send + Sync {
    // Required methods
    fn format_sql_log(
        &self,
        trace_chain: &[TraceNode],
        entry: &SqlLogEntry,
    ) -> String;
    fn format_audit_log(&self, event: &RawAuditEvent) -> String;
}
Expand description

A trait for defining how logs should be formatted before being output

Required Methods§

Source

fn format_sql_log( &self, trace_chain: &[TraceNode], entry: &SqlLogEntry, ) -> String

Format an SQL log entry along with its trace chain

Source

fn format_audit_log(&self, event: &RawAuditEvent) -> String

Format an audit or mutation event log

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§