gloo
gloo copied to clipboard
Set tracestate on trace initiated by gloo from an incoming/transformed header
Gloo Edge Product
Enterprise
Gloo Edge Version
v1.16.7
Is your feature request related to a problem? Please describe.
I want to set tracestate header value based on value of a header created by transformation when trace is initiated by gateway-proxy. Currently envoy only sets empty tracestate when it initiates the trace.
Describe the solution you'd like
An option in tracing provider configuration that would allow that, e.g.:
tracing:
openTelemetryConfig:
tracestateFromHeader: $headerName
collectorUpstreamRef:
namespace: "gloo-system"
name: "opentelemetry-collector"
Describe alternatives you've considered
Using baggage to propagate the header, but it's currently not propagated by upstream services which makes it a non-viable solution. Using a transformation to set the header doesn't work as it's overridden by the tracer.
Additional Context
No such option is currently available in upstream envoy opentelemetry tracer.