kevinhakanson.com

DataDog APM Tracing HTTP Headers

August 07, 2017 #http #monitoring

Update: Might be obsolete based on Datadog + OpenTracing: Embracing the open standard for APM from December 6, 2017


Do the DataDog APM tracing headers to see if they match Zipkin (X-B3-*) or OpenTracing or AWS X-Ray (X-Amzn-Trace-Id) or anything else? Of course not, they use x-ddtrace-*.

It’s hard to find the docs, but look in the official Python source and find them:

parent_trace_id = request.headers.get(‘x-ddtrace-parent_trace_id‘)
parent_span_id = request.headers.get(‘x-ddtrace-parent_span_id‘)

Also, the unofficial Java documents them:

The TraceServletFilter traces every incoming request. If the client request includes the x-ddtrace-parent_trace_id and x-ddtrace-parent_span_id headers, that indicated span is used as the parent trace and span. Otherwise, a new trace is created. Once the request is complete, the new span or trace is closed and sent to Datadog APM.