mirror of
https://github.com/spring-projects/spring-boot.git
synced 2026-10-03 07:49:03 +00:00
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:
+2
-2
@@ -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;
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -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;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user