Skip to content

Commit 4af532b

Browse files
committed
Add starters for Micrometer Metrics
This commit adds spring-boot-starter-micrometer-metrics and spring-boot-starter-micrometer-metrics-test. It also uses the new starters in smoke tests and in other starters, which depended on spring-boot-micrometer-metrics. Closes gh-48161
1 parent cdc7a34 commit 4af532b

File tree

9 files changed

+64
-6
lines changed

9 files changed

+64
-6
lines changed

platform/spring-boot-dependencies/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2205,6 +2205,8 @@ bom {
22052205
"spring-boot-starter-logging",
22062206
"spring-boot-starter-mail",
22072207
"spring-boot-starter-mail-test",
2208+
"spring-boot-starter-micrometer-metrics",
2209+
"spring-boot-starter-micrometer-metrics-test",
22082210
"spring-boot-starter-mongodb",
22092211
"spring-boot-starter-mongodb-test",
22102212
"spring-boot-starter-mustache",

settings.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,8 @@ include "starter:spring-boot-starter-logback"
303303
include "starter:spring-boot-starter-logging"
304304
include "starter:spring-boot-starter-mail"
305305
include "starter:spring-boot-starter-mail-test"
306+
include "starter:spring-boot-starter-micrometer-metrics"
307+
include "starter:spring-boot-starter-micrometer-metrics-test"
306308
include "starter:spring-boot-starter-mongodb"
307309
include "starter:spring-boot-starter-mongodb-test"
308310
include "starter:spring-boot-starter-mustache"

smoke-test/spring-boot-smoke-test-prometheus/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ dependencies {
2828

2929
runtimeOnly('io.micrometer:micrometer-registry-prometheus')
3030

31-
testImplementation(project(":module:spring-boot-micrometer-metrics-test"))
31+
testImplementation(project(":starter:spring-boot-starter-micrometer-metrics-test"))
3232
testImplementation(project(":starter:spring-boot-starter-webmvc-test"))
3333
}
3434

starter/spring-boot-starter-actuator-test/build.gradle

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,5 @@ description = "Starter for testing Spring Boot's Actuator which provides product
2323
dependencies {
2424
api(project(":starter:spring-boot-starter-actuator"))
2525
api(project(":starter:spring-boot-starter-test"))
26-
27-
api(project(":module:spring-boot-micrometer-metrics-test"))
26+
api(project(":starter:spring-boot-starter-micrometer-metrics-test"))
2827
}

starter/spring-boot-starter-actuator/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ description = "Starter for using Spring Boot's Actuator which provides productio
2222

2323
dependencies {
2424
api(project(":starter:spring-boot-starter"))
25+
api(project(":starter:spring-boot-starter-micrometer-metrics"))
2526

2627
api(project(":module:spring-boot-actuator-autoconfigure"))
2728
api(project(":module:spring-boot-health"))
28-
api(project(":module:spring-boot-micrometer-metrics"))
2929

3030
api("io.micrometer:micrometer-observation")
3131
api("io.micrometer:micrometer-jakarta9")
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
/*
2+
* Copyright 2012-present the original author or authors.
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the License);
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* https://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
plugins {
18+
id "org.springframework.boot.starter"
19+
}
20+
21+
description = "Starter for testing Micrometer Metrics"
22+
23+
dependencies {
24+
api(project(":starter:spring-boot-starter-micrometer-metrics"))
25+
api(project(":starter:spring-boot-starter-test"))
26+
27+
api(project(":module:spring-boot-micrometer-metrics-test"))
28+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/*
2+
* Copyright 2012-present the original author or authors.
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the License);
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* https://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
plugins {
18+
id "org.springframework.boot.starter"
19+
}
20+
21+
description = "Starter for using Micrometer Metrics"
22+
23+
dependencies {
24+
api(project(":starter:spring-boot-starter"))
25+
26+
api(project(":module:spring-boot-micrometer-metrics"))
27+
}

starter/spring-boot-starter-opentelemetry-test/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ description = "Starter for testing OpenTelemetry"
2323
dependencies {
2424
api(project(":starter:spring-boot-starter-opentelemetry"))
2525
api(project(":starter:spring-boot-starter-test"))
26+
api(project(":starter:spring-boot-starter-micrometer-metrics-test"))
2627

27-
api(project(":module:spring-boot-micrometer-metrics-test"))
2828
api(project(":module:spring-boot-micrometer-tracing-test"))
2929
}

starter/spring-boot-starter-opentelemetry/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ description = "Starter for using OpenTelemetry"
2222

2323
dependencies {
2424
api(project(":starter:spring-boot-starter"))
25-
api(project(":module:spring-boot-micrometer-metrics"))
25+
api(project(":starter:spring-boot-starter-micrometer-metrics"))
2626
api(project(":module:spring-boot-micrometer-tracing-opentelemetry"))
2727
api(project(":module:spring-boot-opentelemetry"))
2828

0 commit comments

Comments
 (0)