OpenTelemetry SDK
    Preparing search index...

    A sampling result contains a decision for a Span and additional attributes the sampler would like to added to the Span.

    interface SamplingResult {
        attributes?: Readonly<Attributes>;
        decision: SamplingDecision;
        traceState?: TraceState;
    }
    Index

    Properties

    attributes?: Readonly<Attributes>

    The list of attributes returned by SamplingResult MUST be immutable. Caller may call Sampler.shouldSample any number of times and can safely cache the returned value.

    A sampling decision, refer to SamplingDecision for details.

    traceState?: TraceState

    A TraceState that will be associated with the Span through the new SpanContext. Samplers SHOULD return the TraceState from the passed-in Context if they do not intend to change it. Leaving the value undefined will also leave the TraceState unchanged.