SynfraCore
Synfracore
Start Learning
Navigation

Academies

Platform

RoadmapsLabsCertificationsInterviewPYQsAI AssistantCareer
Start Learning Free Learning Roadmaps

OpenTelemetry — Intermediate

Real-world patterns, best practices, and deeper topics

📄
Last updated Nov 2026
Expert Content

OpenTelemetry — Intermediate

Context propagation across process boundaries, in detail

Within a single process, propagating trace context is just passing a value through function calls or a language-specific context object. Across a network call, that context has to be serialized into something the next process can read — almost always an HTTP header (or an equivalent metadata field for gRPC and message queues).

The exact header name and value format are defined by the W3C Trace Context specification, which OTel implements rather than owns — verify the current header syntax against that spec directly rather than from memory, since it is a separate, independently-evolving web standard.

The practical failure mode to watch for: any component sitting between two instrumented services — a proxy, an API gateway, a load balancer — that isn't configured to pass through unrecognized headers will silently drop the propagation header, breaking the trace in two without raising any error. This is usually invisible until someone notices a trace that inexplicably stops at a particular hop.

Baggage: propagating more than just the trace ID

Baggage carries arbitrary key-value pairs alongside the trace context — a tenant ID, a feature-flag variant, a user segment — so a downstream service several hops away can read context set much earlier in the request, without threading it through every intermediate service's own function signatures manually.

Baggage is not free: because it travels on every hop as part of the request's own metadata, adding large or numerous baggage entries adds real overhead to every request in the chain. It's suited to a handful of small, genuinely useful values, not as a general-purpose cross-service data bus.

Resource attributes: describing where telemetry came from

Separate from span/metric-specific attributes, a resource describes the thing producing the telemetry itself — service name, service version, the Kubernetes pod and node it's running on, the cloud region. Resource attributes are attached once per process and automatically included on everything that process emits, rather than being set individually on every span.

text
resource attributes (set once per process):
  service.name: "checkout-api"
  service.version: "2.4.1"
  k8s.pod.name: "checkout-api-7f9c-x2k1"
  cloud.region: "ap-south-1"

Without consistent resource attributes, correlating "which exact pod produced this slow span" during an incident means cross-referencing timestamps by hand instead of filtering directly on an attribute that was already there.

Processors worth knowing beyond batch

The batch processor (group telemetry before exporting, for efficiency) is the one almost every pipeline includes, but several others solve specific real problems:

•filter — drop telemetry matching a condition before it's exported (health-check spans, a noisy debug-level log source).
•attributes — add, rename, or redact attributes in flight, useful for stripping something sensitive before it leaves the Collector.
•tail_sampling — implements tail sampling at the Collector level, deciding what to keep only once a full trace has arrived.
•memory_limiter — protects the Collector itself from running out of memory under a telemetry burst, by shedding load before that happens.

Multiple pipelines, multiple backends, from one Collector

A single Collector deployment is not limited to one backend per signal. The same traces receiver can feed two separate exporters — sending the same data to a primary backend and a cheaper long-term archive simultaneously — by listing both exporters in that pipeline's exporters array. This is a common pattern during a backend migration: run the old and new destinations in parallel for a period, compare them, then drop the old exporter once the new backend is trusted.

One OTLP receiver
Same incoming traces
Batch processor
Shared processing stage
Two exporters
Primary backend + archive, run in parallel
Share:
Join our Community
Daily tips, job alerts, interview help — join engineers learning together
→
Up Next
💬
OpenTelemetry — Interview Q&A
Most asked interview questions with detailed answers
Also Worth Exploring
← Back to all OpenTelemetry modules
← FundamentalsAdvanced →