Distributed tracing is the practice of following a single request as it moves through multiple services, to see where time is spent and where it fails. Each service records spans for the work it does and passes identifying context to the next service, so the pieces can be assembled into one trace that shows the full path.

It is particularly valuable in systems made of many services, where a slow or failing request may involve a long chain of calls and no single log tells the whole story. A trace can show quickly which service or call is responsible.

It works only if the context is passed correctly everywhere. A single service that fails to forward it breaks the trace into disconnected pieces. Tracing also has costs, since the volume of spans can be large, which is why many teams use sampling, and traces can carry sensitive information in attributes.

To implement it, adopt a standard way of propagating trace context across all services and message queues, instrument the main entry and exit points, decide on a sampling policy and make traces linkable from logs by including the trace identifier in log entries. Test that traces remain connected across each service boundary.