obseria.io for Enterprise — SSO, SAML & dedicated support.
obseria.io
STelemetry

Sampling

Collecting a representative subset of traces to control volume and cost without losing insight.

Definition

Sampling is the practice of collecting only a subset of traces (or other telemetry) rather than every event, in order to manage data volume and cost while retaining enough information to diagnose issues. The two main strategies are head-based and tail-based sampling.

In depth

Head-based sampling makes the decision at the start of a request, before the outcome is known — simple but risks dropping slow or erroneous traces. Tail-based sampling buffers spans and makes the decision after the trace is complete, allowing the system to always keep 100% of errors and slow traces while sampling routine traffic. Adaptive sampling automatically adjusts rates based on incoming traffic patterns. The OpenTelemetry Collector supports both strategies via its probabilistic and tail-sampling processors. obseria.io recommends tail-based sampling so that error traces are never dropped, while high-volume healthy traffic is sampled at a configurable rate to control ingestion cost.

Related terms

See Sampling in action

obseria.io gives you full-stack observability — logs, metrics, traces, and AI-powered root cause analysis.

All glossary terms