getsentry / sentry-python

The official Python SDK for Sentry.io
https://sentry.io/for/python/
MIT License
1.93k stars 509 forks source link

Make sampler take into account span type #3766

Closed sentrivana closed 1 week ago

sentrivana commented 1 week ago

The current state of things on the POTel branch is that we treat all spans the same, regardless of whether they're root spans, child spans, or if they have a remote parent. This is a departure from the original logic where e.g. the traces_sampler was only called with transaction events.

Adapt the sampler so that we preserve old sampling behavior with regards to what kind of span we're dealing with.