mirror of
https://github.com/spring-projects/spring-boot.git
synced 2026-10-09 19:09:03 +00:00
Improve null-safety of module/spring-boot-micrometer-metrics
See gh-46926
This commit is contained in:
+2
-1
@@ -78,7 +78,8 @@ public class MetricsEndpoint {
|
||||
}
|
||||
|
||||
@ReadOperation
|
||||
public @Nullable MetricDescriptor metric(@Selector String requiredMetricName, @OptionalParameter List<String> tag) {
|
||||
public @Nullable MetricDescriptor metric(@Selector String requiredMetricName,
|
||||
@OptionalParameter @Nullable List<String> tag) {
|
||||
List<Tag> tags = parseTags(tag);
|
||||
Collection<Meter> meters = findFirstMatchingMeters(this.registry, requiredMetricName, tags);
|
||||
if (meters.isEmpty()) {
|
||||
|
||||
Reference in New Issue
Block a user