Struct slog_redis::Logger[][src]

pub struct Logger { /* fields omitted */ }

A logger that sends JSON formatted logs to a list in a Redis instance. It uses this format

  {
    "@timestamp": ${timeRFC3339},
    "@source_host": ${hostname},
    "@message": ${message},
    "@fields": {
       "level": ${levelLowercase},
       "application": ${appName}
       ... // logged field 1
       ... // logged field 2
       ...
   }

It supports structured logging via slog. You can use the Builder to construct it and then use it as an slog drain.

Trait Implementations

impl Debug for Logger[src]

impl Drain for Logger[src]

type Ok = ()

Type returned by this drain Read more

type Err = Error

Type of potential errors that can be returned by this Drain

Auto Trait Implementations

impl !RefUnwindSafe for Logger

impl Send for Logger

impl Sync for Logger

impl Unpin for Logger

impl !UnwindSafe for Logger

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.