Trait zipkin::sample::Sample [] [src]

pub trait Sample {
    fn sample(&self, trace_id: TraceId) -> bool;
}

A sampler decides whether or not a span should be recorded based on its trace ID.

A trace context received from a remote service may already indicate if the span should be recorded, but if it does not, a Sampler is responsible for making that decision.

Required Methods

Returns true if the span associated with the trace ID should be recorded.

Implementors