-
Notifications
You must be signed in to change notification settings - Fork 41.2k
Update WebClient metrics auto-configuration to the new Observation instrumentation #32518
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
As part of this change, we've deprecated If an application needs to change the Here, let's add a public class CustomClientObservationConvention extends DefaultClientObservationConvention
implements GlobalObservationConvention<ClientObservationContext> {
@Override
public KeyValues getLowCardinalityKeyValues(ClientObservationContext context) {
KeyValues keyValues = super.getLowCardinalityKeyValues(context);
ClientRequest request = context.getCarrier();
return keyValues.and("httpMethod", request.method().name());
}
} |
Since spring-projects/spring-framework#28341, Spring Framework now instruments directly
WebClient
, removing the need for a customExchangeFunction
.With this issue, we should update the auto-configuration to only rely on the new
ObservationRegistry
and configure the instrumentation available onWebClient
. We need to provide a smooth upgrade experience: deprecate the tags providers and adapt them to the new infrastructure until it's completely removed.The text was updated successfully, but these errors were encountered: