Prompt
I’m building a backend with many services what tracing setup should I use
Latest observation
Oct 28, 2026
OpenAI APIWeb search: off
For a backend with many services, the best default is:
Use OpenTelemetry + distributed tracing backend
It’s the current standard for instrumenting microservices and gives you vendor-neutral tracing across all services.
Recommended setup
- Instrumentation: OpenTelemetry SDKs in each service
- Propagation: W3C Trace Context (
traceparent/tracestate) - Collection: OpenTelemetry Collector
- Storage/visualization backend: one of
- Grafana Tempo (great if you already use Grafana)
- Jaeger (good, simple, widely known)
- Honeycomb / Datadog / New Relic / Elastic if you want a managed APM
What to trace
Focus on:
- inbound API requests
- service-to-service calls
- DB queries
- message queue publish/consume
- external HTTP calls
- long-running background jobs
What good tracing should include
Each span should capture:
- operation name
- service name
- duration
- status/error
- key attributes like endpoint, db table, queue name, dependency hostname
- correlation IDs for logs
Practical architecture
A common production setup:
- Services emit OpenTelemetry traces
- OpenTelemetry Collector runs as an agent/sidecar/daemonset
- Collector batches/samples/exports traces
- Traces go to Tempo/Jaeger/managed APM
- Logs and metrics are linked via trace IDs
Sampling
Don’t send every trace forever if traffic is high. Use:
- head sampling for simple control
- tail sampling in the collector if you want to keep slow/error traces and drop boring ones
A good starting point:
- 100% sampling in dev/staging
- 5–20% in production
- always keep error/slow traces if possible
Best practices
- Standardize service names and span names early
- Use a consistent trace propagation format everywhere
- Instrument frameworks and clients, not just request handlers
- Capture errors with stack traces and status codes
- Keep high-cardinality attributes out of trace tags unless necessary
- Correlate logs with trace IDs
If you want the simplest recommendation
OpenTelemetry + Grafana Tempo + Grafana + Loki + Prometheus
This gives you:
- traces in Tempo
- logs in Loki
- metrics in Prometheus
- dashboards/links in Grafana
That’s a strong modern stack for many-service backends.
If you want, I can also suggest:
- a stack based on your language/framework, or
- a concrete deployment design for Kubernetes vs VMs.