Skip to main content

Diagnostic

Trait Diagnostic 

Source
pub trait Diagnostic {
    // Required methods
    fn type_(&self) -> &str;
    fn content_type(&self) -> HeaderValue;
    fn safe_loggable(&self) -> bool;
    fn result(&self) -> Result<Bytes, Error>;
}
Expand description

An SLS diagnostic. See the SLS debug spec

Required Methods§

Source

fn type_(&self) -> &str

The type of the diagnostic. Must be lower cased, dot delimited, and end with a version.

Example: “my.diagnostic.v1”

Source

fn content_type(&self) -> HeaderValue

The value of the “Content-Type” header.

Example: “application/json”

Source

fn safe_loggable(&self) -> bool

Whether the value is safe to log

Source

fn result(&self) -> Result<Bytes, Error>

The bytes of the response to send

Implementors§