Struct console_api::async_ops::AsyncOp
source · pub struct AsyncOp {
pub id: Option<Id>,
pub metadata: Option<MetaId>,
pub source: String,
pub parent_async_op_id: Option<Id>,
pub resource_id: Option<Id>,
}
Expand description
An async operation.
An async operation is an operation that is associated with a resource This could, for example, be a a read or write on a TCP stream, or a receive operation on a channel.
Fields§
§id: Option<Id>
The async op’s ID.
This uniquely identifies this op across all currently live ones.
metadata: Option<MetaId>
The numeric ID of the op’s Metadata
.
This identifies the Metadata
that describes the tracing
span
corresponding to this async op. The metadata for this ID will have been sent
in a prior RegisterMetadata
message.
source: String
The source of this async operation. Most commonly this should be the name of the method where the instantiation of this op has happened.
parent_async_op_id: Option<Id>
The ID of the parent async op.
This field is only set if this async op was created while inside of another
async op. For example, tokio::sync
’s Mutex::lock
internally calls
Semaphore::acquire
.
This field can be empty; if it is empty, this async op is not a child of another async op.
resource_id: Option<Id>
The resources’s ID.
Trait Implementations§
source§impl Message for AsyncOp
impl Message for AsyncOp
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8, Global>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8, Global>where Self: Sized,
source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8, Global>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8, Global>where Self: Sized,
source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
self
. Read moresource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
self
.source§impl PartialEq<AsyncOp> for AsyncOp
impl PartialEq<AsyncOp> for AsyncOp
impl StructuralPartialEq for AsyncOp
Auto Trait Implementations§
impl RefUnwindSafe for AsyncOp
impl Send for AsyncOp
impl Sync for AsyncOp
impl Unpin for AsyncOp
impl UnwindSafe for AsyncOp
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request