open-telemetry / opentelemetry-java-contrib

https://opentelemetry.io
Apache License 2.0
158 stars 126 forks source link

Baggage span processor - key predicate #1295

Closed MikeGoldsmith closed 3 months ago

MikeGoldsmith commented 5 months ago

This issue is to track adding a method of selecting what baggage key entries should be copied.

Feedback in the JS contrib PR was to allow a user-provided predicate function. This puts the responsibility on the user to ensure sensitive baggage keys are not copied while also not prescribing how that is determined.

We had a similar discussion in the .NET contrib project but thought it was more complicated than just using a set of prefixes so created an issue to continue the discussion. The plain processor that copies all baggage entries (like using * in your example) is likely to be accepted first.

Originally posted by @MikeGoldsmith in https://github.com/open-telemetry/opentelemetry-java-contrib/issues/1290#issuecomment-2078000503

MikeGoldsmith commented 3 months ago

Closed by: