pub trait InstrumentAwait: Future + Sized {
// Provided methods
fn instrument_await(
self,
span: impl Into<Span>,
) -> Instrumented<Self, false> ⓘ { ... }
fn verbose_instrument_await(
self,
span: impl Into<Span>,
) -> Instrumented<Self, true> ⓘ { ... }
}
Expand description
Attach spans to a future to be traced in the await-tree.
Provided Methods§
Sourcefn instrument_await(self, span: impl Into<Span>) -> Instrumented<Self, false> ⓘ
fn instrument_await(self, span: impl Into<Span>) -> Instrumented<Self, false> ⓘ
Instrument the future with a span.
Sourcefn verbose_instrument_await(
self,
span: impl Into<Span>,
) -> Instrumented<Self, true> ⓘ
fn verbose_instrument_await( self, span: impl Into<Span>, ) -> Instrumented<Self, true> ⓘ
Instrument the future with a verbose span, which is optionally enabled based on the registry configuration.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.