Merge branch '2.6.x' into 2.7.x

Closes gh-30851
This commit is contained in:
Andy Wilkinson
2022-05-03 15:14:19 +01:00
51 changed files with 105 additions and 106 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -50,7 +50,7 @@ public class AvailabilityStateHealthIndicator extends AbstractHealthIndicator {
* @param <S> the availability state type
* @param applicationAvailability the application availability
* @param stateType the availability state type
* @param statusMappings consumer used to setup the status mappings
* @param statusMappings consumer used to set up the status mappings
*/
public <S extends AvailabilityState> AvailabilityStateHealthIndicator(
ApplicationAvailability applicationAvailability, Class<S> stateType,

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -357,7 +357,7 @@ public abstract class EndpointDiscoverer<E extends ExposableEndpoint<O>, O exten
/**
* Create a new {@link OperationKey} instance.
* @param key the underlying key for the operation
* @param description a human readable description of the key
* @param description a human-readable description of the key
*/
public OperationKey(Object key, Supplier<String> description) {
Assert.notNull(key, "Key must not be null");

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -225,7 +225,7 @@ public class MetricsEndpoint {
}
/**
* A set of tags for further dimensional drilldown and their potential values.
* A set of tags for further dimensional drill-down and their potential values.
*/
public static final class AvailableTag {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2021 the original author or authors.
* Copyright 2012-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -115,7 +115,7 @@ public class PrometheusPushGatewayManager {
this.pushGateway.delete(this.job, this.groupingKey);
}
catch (Throwable ex) {
logger.warn("Unexpected exception thrown while deleting metrics from Promethues Pushgateway", ex);
logger.warn("Unexpected exception thrown while deleting metrics from Prometheus Pushgateway", ex);
}
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -133,7 +133,7 @@ class CassandraDriverHealthIndicatorTests {
}
@Test
void healthWithcassandraDownShouldReturnDown() {
void healthWithCassandraDownShouldReturnDown() {
CqlSession session = mock(CqlSession.class);
given(session.getMetadata()).willThrow(new DriverTimeoutException("Test Exception"));
CassandraDriverHealthIndicator healthIndicator = new CassandraDriverHealthIndicator(session);

View File

@@ -73,9 +73,9 @@ class StartupTimeMetricsListenerTests {
void metricRecordedWithoutMainAppClassTag() {
SpringApplication application = mock(SpringApplication.class);
this.listener.onApplicationEvent(new ApplicationStartedEvent(application, null, null, Duration.ofSeconds(2)));
TimeGauge applicationStartedGague = this.registry.find("application.started.time").timeGauge();
assertThat(applicationStartedGague).isNotNull();
assertThat(applicationStartedGague.getId().getTags()).isEmpty();
TimeGauge applicationStartedGauge = this.registry.find("application.started.time").timeGauge();
assertThat(applicationStartedGauge).isNotNull();
assertThat(applicationStartedGauge.getId().getTags()).isEmpty();
}
@Test

View File

@@ -659,7 +659,7 @@ class QuartzEndpointTests {
}
@Test
void quartzJobWithSensitiveDataMapAndCustomSanitizier() throws SchedulerException {
void quartzJobWithSensitiveDataMapAndCustomSanitizer() throws SchedulerException {
JobDetail job = JobBuilder.newJob(Job.class).withIdentity("hello", "samples").usingJobData("test", "value")
.usingJobData("secret", "value").build();
mockJobs(job);