cloudfoundry / gorouter

CF Router
Apache License 2.0
441 stars 224 forks source link

feat: Add TraceInfo to HTTPStartStop envelopes #407

Closed ctlong closed 5 months ago

ctlong commented 5 months ago

A short explanation of the proposed change:

Adds the span ID and trace ID for each request to the corresponding HTTPStartStop envelopes as tags, if they're present.

An explanation of the use cases your change solves

Should help operators and developers to track their traces through gorouter (see https://github.com/cloudfoundry/routing-release/issues/308).

Also aids corresponding work within the OTel Collector to export HTTPStartStop envelopes as traces.

Instructions to functionally test the behavior change using operator interfaces (BOSH manifest, logs, curl, and metrics)

Expected result after the change

HTTPStartStop envelopes emitted by Gorouter (converted to loggregator v2 timers in the UDP Forwarder Agent) are tagged with the corresponding HTTP request's trace ID and span ID.

Current result before the change

HTTPStartStop envelopes emitted by Gorouter (converted to loggregator v2 timers in the UDP Forwarder Agent) are not tagged with the corresponding HTTP request's trace ID and span ID.

Links to any other associated PRs

None