Skip to content

Commit c2bdbb0

Browse files
committed
Move code from spring-boot-actuator to spring-boot-http-client-reactive
1 parent 66f1cbd commit c2bdbb0

File tree

6 files changed

+13
-13
lines changed

6 files changed

+13
-13
lines changed

spring-boot-project/spring-boot-actuator-autoconfigure/src/main/java/org/springframework/boot/actuate/autoconfigure/observation/web/client/WebClientObservationConfiguration.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2023 the original author or authors.
2+
* Copyright 2012-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -21,8 +21,8 @@
2121
import org.springframework.beans.factory.ObjectProvider;
2222
import org.springframework.boot.actuate.autoconfigure.metrics.MetricsProperties;
2323
import org.springframework.boot.actuate.autoconfigure.observation.ObservationProperties;
24-
import org.springframework.boot.actuate.metrics.web.reactive.client.ObservationWebClientCustomizer;
2524
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
25+
import org.springframework.boot.http.client.reactive.web.actuate.observation.ObservationWebClientCustomizer;
2626
import org.springframework.context.annotation.Bean;
2727
import org.springframework.context.annotation.Configuration;
2828
import org.springframework.web.reactive.function.client.ClientRequestObservationConvention;
@@ -35,7 +35,7 @@
3535
* @author Brian Clozel
3636
*/
3737
@Configuration(proxyBeanMethods = false)
38-
@ConditionalOnClass(WebClient.class)
38+
@ConditionalOnClass({ WebClient.class, ObservationWebClientCustomizer.class })
3939
class WebClientObservationConfiguration {
4040

4141
@Bean

spring-boot-project/spring-boot-actuator-autoconfigure/src/test/java/org/springframework/boot/actuate/autoconfigure/observation/web/client/WebClientObservationConfigurationTests.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2024 the original author or authors.
2+
* Copyright 2012-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -28,8 +28,8 @@
2828

2929
import org.springframework.boot.actuate.autoconfigure.metrics.test.MetricsRun;
3030
import org.springframework.boot.actuate.autoconfigure.observation.ObservationAutoConfiguration;
31-
import org.springframework.boot.actuate.metrics.web.reactive.client.ObservationWebClientCustomizer;
3231
import org.springframework.boot.autoconfigure.AutoConfigurations;
32+
import org.springframework.boot.http.client.reactive.web.actuate.observation.ObservationWebClientCustomizer;
3333
import org.springframework.boot.http.client.reactive.web.autoconfigure.WebClientAutoConfiguration;
3434
import org.springframework.boot.test.context.assertj.AssertableApplicationContext;
3535
import org.springframework.boot.test.context.runner.ApplicationContextRunner;

spring-boot-project/spring-boot-http-client-reactive/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ dependencies {
2424
testImplementation(project(":spring-boot-project:spring-boot-test"))
2525
testImplementation(project(":spring-boot-project:spring-boot-tomcat"))
2626
testImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-test-support"))
27+
testImplementation("io.micrometer:micrometer-observation-test")
2728

2829
testRuntimeOnly("ch.qos.logback:logback-classic")
2930
}
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2023 the original author or authors.
2+
* Copyright 2012-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
package org.springframework.boot.actuate.metrics.web.reactive.client;
17+
package org.springframework.boot.http.client.reactive.web.actuate.observation;
1818

1919
import io.micrometer.observation.ObservationRegistry;
2020

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2019 the original author or authors.
2+
* Copyright 2012-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -15,7 +15,6 @@
1515
*/
1616

1717
/**
18-
* Actuator support for {@link org.springframework.web.reactive.function.client.WebClient}
19-
* metrics.
18+
* Observation integration for WebClient.
2019
*/
21-
package org.springframework.boot.actuate.metrics.web.reactive.client;
20+
package org.springframework.boot.http.client.reactive.web.actuate.observation;
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2023 the original author or authors.
2+
* Copyright 2012-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
package org.springframework.boot.actuate.metrics.web.reactive.client;
17+
package org.springframework.boot.http.client.reactive.web.actuate.observation;
1818

1919
import io.micrometer.observation.tck.TestObservationRegistry;
2020
import org.junit.jupiter.api.Test;

0 commit comments

Comments
 (0)