[][src]Struct opentelemetry::sdk::trace::Config

pub struct Config {
    pub default_sampler: Box<dyn ShouldSample>,
    pub id_generator: Box<dyn IdGenerator>,
    pub max_events_per_span: u32,
    pub max_attributes_per_span: u32,
    pub max_links_per_span: u32,
    pub resource: Arc<Resource>,
}

Tracer configuration

Fields

default_sampler: Box<dyn ShouldSample>

The sampler that the sdk should use

id_generator: Box<dyn IdGenerator>

The id generator that the sdk should use

max_events_per_span: u32

The max events that can be added to a Span.

max_attributes_per_span: u32

The max attributes that can be added to a Span.

max_links_per_span: u32

The max links that can be added to a Span.

resource: Arc<Resource>

Contains attributes representing an entity that produces telemetry.

Implementations

impl Config[src]

pub fn with_default_sampler<T: ShouldSample + 'static>(self, sampler: T) -> Self[src]

Specify the default sampler to be used.

pub fn with_id_generator<T: IdGenerator + 'static>(
    self,
    id_generator: T
) -> Self
[src]

Specify the id generator to be used.

pub fn with_max_events_per_span(self, max_events: u32) -> Self[src]

Specify the number of events to be recorded per span.

pub fn with_max_attributes_per_span(self, max_attributes: u32) -> Self[src]

Specify the number of attributes to be recorded per span.

Specify the number of events to be recorded per span.

pub fn with_resource(self, resource: Resource) -> Self[src]

Specify the attributes representing the entity that produces telemetry

Trait Implementations

impl Debug for Config[src]

impl Default for Config[src]

fn default() -> Self[src]

Create default global sdk configuration.

Auto Trait Implementations

impl !RefUnwindSafe for Config

impl Send for Config

impl Sync for Config

impl Unpin for Config

impl !UnwindSafe for Config

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,