Trait observability::OpenSpanExt[][src]

pub trait OpenSpanExt {
    fn get_context(&self) -> Context;
fn get_current_context() -> Context;
fn get_current_bytes() -> Vec<u8>;
fn set_context(&self, context: Context);
fn set_current_context(context: Context);
fn set_current_bytes(bytes: Vec<u8>);
fn display_context(&self) -> String; fn get_context_bytes(&self) -> Vec<u8> { ... }
fn set_from_bytes(&self, bytes: Vec<u8>) { ... } }

Opentelemetry span extension trait. This trait provides helper methods to the tracing::Span for crossing thread and process boundaries.

Required methods

fn get_context(&self) -> Context[src]

Get the context of this span.

fn get_current_context() -> Context[src]

Get the context of the current span.

fn get_current_bytes() -> Vec<u8>[src]

Get the current span as message pack bytes.

fn set_context(&self, context: Context)[src]

Set the context of this span.

fn set_current_context(context: Context)[src]

Set the context of the current span.

fn set_current_bytes(bytes: Vec<u8>)[src]

Set the current span context from message pack bytes.

fn display_context(&self) -> String[src]

Display this spans context as a String.

Loading content...

Provided methods

fn get_context_bytes(&self) -> Vec<u8>[src]

Get the context as message pack bytes for sending over process boundaries.

fn set_from_bytes(&self, bytes: Vec<u8>)[src]

Set the context of this span from bytes over the network.

Loading content...

Implementations on Foreign Types

impl OpenSpanExt for Span[src]

Loading content...

Implementors

Loading content...