Skip to content

Resolve the logs/traces sampling priority discrepancy in probabilistic sampler processor #38469

Open
@jmacd

Description

@jmacd

Component(s)

processor/probabilisticsampler

What happened?

Description

See https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/processor/probabilisticsamplerprocessor/README.md#sampling-priority

Steps to Reproduce

This is a historical conflict.

Expected Result

The logs priority mechanism has proven useful because it allows OTTL transforms to configure sampling probabilities ahead of this processor, which simply does the math.

Actual Result

In traces, the sampling priority mechanism forces a pass-through, instead of overriding the sampling probability (as done in logs).

See #36876 (comment)

This calls for adding a feature flag to change how traces sampling_priority behavior works, at least that is the solution I would prefer.

Collector version

v0.120.0

Environment information

Environment

OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")

OpenTelemetry Collector configuration

Log output

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions