Function set_default
pub fn set_default<S>(subscriber: S) -> DefaultGuard
Available on crate features
dep_tracing
and alloc
only.Expand description
Sets the Subscriber
as the default for the current thread for the
duration of the lifetime of the returned DefaultGuard
.
The default subscriber is used when creating a new Span
or Event
.