Skip to main content

initialize_logging_with

Function initialize_logging_with 

Source
pub fn initialize_logging_with<L>(extra: Option<L>)
where L: Layer<FmtSubscriber> + Send + Sync + 'static,
Expand description

Initializes logging with an optional extra Layer (e.g. an OTel bridge).

The extra layer must implement Layer<FmtSubscriber>. A polymorphic layer like OpenTelemetryTracingBridge satisfies this naturally.