Skip to content

Automatic baggage propagation from gRPC metadata#369

Open
o-shevchenko wants to merge 2 commits intospring-projects:mainfrom
o-shevchenko:gh-368
Open

Automatic baggage propagation from gRPC metadata#369
o-shevchenko wants to merge 2 commits intospring-projects:mainfrom
o-shevchenko:gh-368

Conversation

@o-shevchenko
Copy link
Contributor

@o-shevchenko o-shevchenko commented Feb 5, 2026

Implements automatic propagation of OpenTelemetry baggage between gRPC services via metadata headers.
Integrate it with current Spring Boot actuator confs for HTTP headers

Client side: GrpcHeaderClientInterceptor propagates baggage values as gRPC metadata headers in outbound calls based on management.tracing.baggage.remote-fields configuration.

Server side: GrpcHeaderServerInterceptor extracts metadata headers into baggage for downstream propagation and adds them as span tags based on management.tracing.baggage.tag-fields configuration.

[resolves #368]

@o-shevchenko o-shevchenko force-pushed the gh-368 branch 3 times, most recently from 083b4dd to a9479ba Compare February 5, 2026 12:13
@o-shevchenko
Copy link
Contributor Author

CI build is broken
Opened PR #370

Implements automatic propagation of OpenTelemetry baggage between
gRPC services via metadata headers.

Client side: GrpcHeaderClientInterceptor propagates baggage values
as gRPC metadata headers in outbound calls based on
management.tracing.baggage.remote-fields configuration.

Server side: GrpcHeaderServerInterceptor extracts metadata headers
into baggage for downstream propagation and adds them as span tags
based on management.tracing.baggage.tag-fields configuration.

Both interceptors properly manage BaggageInScope lifecycle with
guaranteed cleanup on call completion or cancellation.

Signed-off-by: Oleksandr Shevchenko <shevchenko.olexandr96@gmail.com>
@onobc
Copy link
Contributor

onobc commented Feb 5, 2026

👋🏻 @o-shevchenko ,

Thank you for the contribution 🎉 !

Note

🚧 🚧 🚧

Because this change resides in the auto-configuration which we are in the process of moving to Spring Boot (see #234) we will review this but merging will be delayed until after the migration completes.

Please pardon our mess while under construction 👷🏻 🏗️ .

Thank you for your patience.

@onobc onobc modified the milestone: 1.1.0 Feb 5, 2026
@onobc onobc added status: post-spring-boot-migration Must wait until after #234 is complete enhancement New feature or request labels Feb 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request status: post-spring-boot-migration Must wait until after #234 is complete

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support automatic baggage propagation from gRPC metadata

2 participants