Reactive Security OAuth2 client doesn't propagate traces and baggage's in Spring Boot 3 #14946
Labels
in: oauth2
An issue in OAuth2 modules (oauth2-core, oauth2-client, oauth2-resource-server, oauth2-jose)
type: enhancement
A general enhancement
Describe the bug
The current version of Reactive OAuth Security doesn't follow all Observability documentation recommendations, therefore it doesn't propagate trace and baggage's over network. See: Docs Spring.io - 8.4. Propagating Traces
Class example:
oauth2/oauth2-client/src/main/java/org/springframework/security/oauth2/client/endpoint/AbstractWebClientReactiveOAuth2AccessTokenResponseClient.java
Where
WebClient.Builder()
is used statically - therefore it has NOOPObservationRegistry
and doesn't register Request Observations, and doesn't allow propagating traces (for example B3 Brave Zipkin Baggage's propagation).To Reproduce
Creating Reactive OAuth client and trying to send traces and baggage's to authentication server.
Expected behavior
OAuth calls from client to server in Reactive Security and Spring Boot 3 start proper request observations and propagate baggage's.
The text was updated successfully, but these errors were encountered: