Support decide sampling in all span lifecycle #4171
Labels
spec:trace
Related to the specification/trace directory
triage:deciding:community-feedback
Open to community discussion. If the community can provide sufficient reasoning, it may be accepted
In the current header sampling mechanism, the samplingResult is depend on Instrumenter.start(), such as parent or traceIdRatio.
When the samplingResult create ends, there may be an invocation exception in instrument target method, and exception is usually the information we focus on. so, i think if we can support sample decide in span lifecycle(e.g. create / set attributes / end),it will be perfect.
for example, two scenes as below:
1.tail sampling: got 100% spans in one trace. but if we want sample all error spans, it require 100% sample.
2.new head sampling: support decide samle on span lifecycle in agent. Do not require 100% sample, it may lose some other service's spans in whole trace,may got only 50%spans in one trace, but the 50% is important. I think it's acceptable
So, can it support decide sample in all span lifecycle?
The text was updated successfully, but these errors were encountered: