opentelemetry-php icon indicating copy to clipboard operation
opentelemetry-php copied to clipboard

port RuleBasedSampler to opentelemetry-php-contrib

Open brettmc opened this issue 1 year ago • 0 comments

A proof-of-concept sampler, https://github.com/Nevay/otel-sdk-contrib-sampler was created to demonstrate a rules-based sampler, as an improvement over the sampler proposed in #1208 . A RuleBasedSampler is mentioned in https://github.com/open-telemetry/oteps/pull/240

Since a Rule-based sampler is not part of the otel specification, it should initially live in opentelemetry-php-contrib repo. It won't be initially supported to enable/configure via environment variables, but it can be configured via code. If the above OTEP is accepted and implemented, then we can use that mechanism to automatically enable/configure the sampler.

If it can be implemented without adding external dependencies (eg symfony/config) that will help if it ever becomes a core component (since we try to minimize dependencies, and code to interfaces).

brettmc avatar Jan 19 '24 02:01 brettmc