evanderkoogh / otel-cf-workers

An OpenTelemetry compatible library for instrumenting and exporting traces for Cloudflare Workers
BSD 3-Clause "New" or "Revised" License
208 stars 39 forks source link

Expose function to return trace header #146

Open psteinroe opened 3 weeks ago

psteinroe commented 3 weeks ago

We are using QStash and would like to setup distributed tracing across jobs. Unfortunately, QStash adds a prefix to the custom headers. Afaik, this library extracts potential parent traces from the standard header. Is it possible to make the name of the header configurable? Or even simpler, add a "extract" function that we can run before the headers are accessed and that returns the new "header" object?