Open Q&A
If there's no good subforum for your question - ask it here!
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How does the sampling precedence work ?

kunal_vaidya
Observer

Hello ,

we generate spans through multiples sources (one agent on the node, istio otel integration and otel in the application code). 

Problem here is the traces are missing or inconsistent or getting overridden as there are multiple layers. The behaviour is quite intermittent. 

Keen to know few things ? 

- Will OneAgent tracing will have highest precedence and sampling rates set for those will be in action ?

- Will the Isito ones will have higher precedence ? 

(Apparently OA merges them into one and trigger a new trace)

Thanks heaps

2 REPLIES 2

AntonPineiro
DynaMight Guru
DynaMight Guru

Hi,

Trace sampling docs maybe are useful.

Best regards

❤️ Emacs ❤️ Vim ❤️ Bash ❤️ Perl

sujit_k_singh
Advisor

 

When multiple instrumentation layers (OneAgent, Istio, and application-level OpenTelemetry) are active, there is no global “precedence” for sampling. Each component applies its own sampling rules when it starts a trace. If Istio initiates a trace, its sampling decision governs that trace; if the application or OneAgent starts first, their respective sampling applies. Dynatrace can merge spans from different sources into a single PurePath if W3C trace context is consistently propagated, but this does not override sampling decisions already made. To avoid missing or inconsistent traces, choose a single trace starter (e.g., Istio or app OTel), enforce W3C context propagation across all services, and configure OneAgent to join existing traces rather than compete.

Dynatrace documentation for reference:

Trace sampling (OneAgent)

Enable OpenTelemetry Span Sensor for OneAgent

Configure OpenTelemetry tracing with Istio

Ingest traces overview

Dynatrace Professional Certified

Featured Posts