apm-agent-nodejs icon indicating copy to clipboard operation
apm-agent-nodejs copied to clipboard

add W3C baggage support

Open trentm opened this issue 4 years ago • 3 comments

https://w3c.github.io/baggage/

Along with 'traceparent' and 'tracestate', we could have the Node.js APM agent (and, of course, the other agents):

  1. propagate the baggage header; and
  2. provide APIs to add/get/remote baggage

At time of writing, the baggage spec is still a "First Public Working Draft (FPWD)" so priority is probably lower. One concrete possible use case (not definitive yet) is this Kibana issue -- https://github.com/elastic/kibana/issues/97934 -- to attempt to propagate info on a Kibana action (front end or back end) all the way through to an Elasticsearch slowlogs entry. https://github.com/elastic/kibana/issues/97934#issuecomment-854257718 is a description of the idea.

trentm avatar Jun 08 '21 20:06 trentm

Will this realistically be prioritized at any point? this is still a requierement for https://github.com/elastic/kibana/issues/101708.

pgayvallet avatar Jul 05 '24 08:07 pgayvallet

@pgayvallet It is unlikely that this will be prioritized. The focus is currently on OpenTelemetry: both the upstream github.com/open-telemetry repos and our distribution at https://github.com/elastic/elastic-otel-node/tree/main/packages/opentelemetry-node#readme, and both of which support baggage.

I think a better longer-term bet would be to consider moving Kibana's self-instrumentation to using OTel. However, granted that would be some effort.

trentm avatar Jul 05 '24 21:07 trentm

Yeah I agree it would make sense.

cc @lukeelmers: would it be worth opening an issue in the Kibana repo to discuss about OTel instrumentation for Kibana?

pgayvallet avatar Jul 10 '24 12:07 pgayvallet