Lesson 10 · Traces, logs & the whole picture
OTel Collector & Jaeger
Where all the spans go — a pipeline that receives, samples, and stores traces.
Your win: explain the OpenTelemetry Collector's receiver → processor → exporter pipeline, why tail sampling matters, and read this repo's collector config and Jaeger backend.
The Collector is a pipeline
Lesson 9's spans (from Go apps and Envoy) need somewhere to go. The OpenTelemetry Collector is a vendor-neutral pipeline that ingests telemetry, processes it, and exports it onward — decoupling "who produces spans" from "where they're stored".1 Three stages:
| Stage | Does |
|---|---|
| Receivers | ingest spans in some protocol (OTLP, Jaeger, Zipkin) |
| Processors | batch, sample, transform, enrich |
| Exporters | send to a backend (Jaeger) or another system |
- Receivers (:6-24):
otlp(:4317/:4318, the Go apps),jaeger(:14268), andzipkin(:9411) — where Istio sends. So one collector accepts spans from every source. - Processors (:26-77):
batch+tail_sampling. - Exporters (:138-155):
otlp→jaeger-all-in-one:4317, plus aprometheusexporter (:8889) that turns spans into metrics. - Pipeline (:173-182):
traces: [otlp, zipkin] → [batch, tail_sampling] → jaeger.
Tail sampling — the clever cost lever
tail_sampling does the real reduction: keep traces with
latency > 800ms, or a 5xx/gRPC-error/timeout, and drop the noise (hasura/cypress/grafana,
/Subscribe streams) (values.yaml:32-77). You end up
storing the slow and failing traces — exactly the ones you'd want when debugging.
jaegertracing/all-in-one:1.52, jaeger-all-in-one/values.yaml:7-11)
— a single binary bundling collector + storage (Badger, 10Gi) + the query UI (:16686) — not
the distributed multi-component Jaeger. Honest scale note: all-in-one is simple and fine for
this volume, but it's a single point of storage; a higher-scale setup would split Jaeger into
separate collector/query/storage. Knowing that distinction is a good interview signal.
OpenTelemetry Collector + Jaeger
The receiver/processor/exporter model, tail sampling, and the Jaeger backend.
→ opentelemetry.io — Collector
→ jaegertracing.io — Jaeger docs
Check yourself (from memory)
Q1. The OTel Collector's three stages are…
Q2. Tail sampling beats head sampling because it…
Q3. Istio's Envoy sends its spans to the collector's…
values.yaml:173-182): traces:
[otlp, zipkin] → [batch, tail_sampling] → jaeger-all-in-one:4317; also a prometheus
exporter (:8889, spans→metrics). TAIL SAMPLING (vs head): decide AFTER the trace completes →
keep latency>800ms + 5xx/gRPC-error/timeout, drop noise (hasura/cypress//Subscribe).
Apps sample 100% up front; the collector does the real reduction. Backend = JAEGER ALL-IN-ONE
(single binary: collector+Badger storage+UI:16686, image 1.52) — simple, single storage point;
distributed Jaeger would split it for scale.1. OpenTelemetry — Collector; in-repo platforms/monitoring/opentelemetry-collector/values.yaml.