Harmonize ObservationConvention parameters in gRPC support

Such parameters are usually named "customConvention" so this commit
aligns to that naming.

See gh-49730
This commit is contained in:
Stéphane Nicoll
2026-03-26 08:38:42 +01:00
parent f368ac4805
commit d7a4561da8
2 changed files with 4 additions and 4 deletions
@@ -53,9 +53,9 @@ public final class GrpcClientObservationAutoConfiguration {
@GlobalClientInterceptor
@ConditionalOnMissingBean
ObservationGrpcClientInterceptor grpcClientObservationInterceptor(ObservationRegistry observationRegistry,
ObjectProvider<GrpcClientObservationConvention> convention) {
ObjectProvider<GrpcClientObservationConvention> customConvention) {
ObservationGrpcClientInterceptor interceptor = new ObservationGrpcClientInterceptor(observationRegistry);
convention.ifAvailable(interceptor::setCustomConvention);
customConvention.ifAvailable(interceptor::setCustomConvention);
return interceptor;
}
@@ -58,9 +58,9 @@ public final class GrpcServerObservationAutoConfiguration {
@GlobalServerInterceptor
@ConditionalOnMissingBean
ObservationGrpcServerInterceptor grpcServerObservationInterceptor(ObservationRegistry observationRegistry,
ObjectProvider<GrpcServerObservationConvention> convention) {
ObjectProvider<GrpcServerObservationConvention> customConvention) {
ObservationGrpcServerInterceptor interceptor = new ObservationGrpcServerInterceptor(observationRegistry);
convention.ifAvailable(interceptor::setCustomConvention);
customConvention.ifAvailable(interceptor::setCustomConvention);
return interceptor;
}