Merge branch '3.1.x' into 3.2.x

Closes gh-39091
This commit is contained in:
Andy Wilkinson 2024-01-11 09:56:35 +00:00
commit 7087897507
150 changed files with 358 additions and 353 deletions

View File

@ -31,8 +31,13 @@ if (versions.springFramework.contains("-")) {
}
}
checkstyle {
toolVersion = "10.12.4"
}
dependencies {
checkstyle "io.spring.javaformat:spring-javaformat-checkstyle:${javaFormatVersion}"
checkstyle("com.puppycrawl.tools:checkstyle:${checkstyle.toolVersion}")
checkstyle("io.spring.javaformat:spring-javaformat-checkstyle:${javaFormatVersion}")
implementation(platform("org.springframework:spring-framework-bom:${versions.springFramework}"))
implementation("com.diffplug.gradle:goomph:3.37.2")
@ -58,10 +63,6 @@ dependencies {
testRuntimeOnly("org.junit.platform:junit-platform-launcher")
}
checkstyle {
toolVersion = "10.12.4"
}
gradlePlugin {
plugins {
annotationProcessorPlugin {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -243,6 +243,8 @@ class JavaConventions {
checkstyle.getConfigDirectory().set(project.getRootProject().file("src/checkstyle"));
String version = SpringJavaFormatPlugin.class.getPackage().getImplementationVersion();
DependencySet checkstyleDependencies = project.getConfigurations().getByName("checkstyle").getDependencies();
checkstyleDependencies
.add(project.getDependencies().create("com.puppycrawl.tools:checkstyle:" + checkstyle.getToolVersion()));
checkstyleDependencies
.add(project.getDependencies().create("io.spring.javaformat:spring-javaformat-checkstyle:" + version));
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -62,7 +62,7 @@ class SkipSslVerificationHttpRequestFactory extends SimpleClientHttpRequestFacto
return context.getSocketFactory();
}
private static class SkipHostnameVerifier implements HostnameVerifier {
private static final class SkipHostnameVerifier implements HostnameVerifier {
@Override
public boolean verify(String s, SSLSession sslSession) {
@ -71,7 +71,7 @@ class SkipSslVerificationHttpRequestFactory extends SimpleClientHttpRequestFacto
}
private static class SkipX509TrustManager implements X509TrustManager {
private static final class SkipX509TrustManager implements X509TrustManager {
@Override
public X509Certificate[] getAcceptedIssuers() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -54,7 +54,7 @@ public class LogFileWebEndpointAutoConfiguration {
return new LogFileWebEndpoint(logFile.getIfAvailable(), properties.getExternalFile());
}
private static class LogFileCondition extends SpringBootCondition {
private static final class LogFileCondition extends SpringBootCondition {
@Override
public ConditionOutcome getMatchOutcome(ConditionContext context, AnnotatedTypeMetadata metadata) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -92,7 +92,7 @@ public class JerseyServerMetricsAutoConfiguration {
/**
* An {@link AnnotationFinder} that uses {@link AnnotationUtils}.
*/
private static class AnnotationUtilsAnnotationFinder implements AnnotationFinder {
private static final class AnnotationUtilsAnnotationFinder implements AnnotationFinder {
@Override
public <A extends Annotation> A findAnnotation(AnnotatedElement annotatedElement, Class<A> annotationType) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -311,7 +311,7 @@ public final class EndpointRequest {
/**
* Factory used to create a {@link RequestMatcher}.
*/
private static class RequestMatcherFactory {
private static final class RequestMatcherFactory {
RequestMatcher antPath(RequestMatcherProvider matcherProvider, String... parts) {
StringBuilder pattern = new StringBuilder();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -75,7 +75,7 @@ class CloudFoundryReactiveHealthEndpointWebExtensionTests {
});
}
private static class TestHealthIndicator implements HealthIndicator {
private static final class TestHealthIndicator implements HealthIndicator {
@Override
public Health health() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -70,7 +70,7 @@ class CloudFoundryHealthEndpointWebExtensionTests {
});
}
private static class TestHealthIndicator implements HealthIndicator {
private static final class TestHealthIndicator implements HealthIndicator {
@Override
public Health health() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -138,7 +138,7 @@ class HealthEndpointDocumentationTests extends MockMvcEndpointDocumentationTests
}
private static class TestHealthEndpointGroup implements HealthEndpointGroup {
private static final class TestHealthEndpointGroup implements HealthEndpointGroup {
private final StatusAggregator statusAggregator = new SimpleStatusAggregator();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -561,11 +561,11 @@ class ObservationAutoConfigurationTests {
}
private static class CustomContext extends Context {
private static final class CustomContext extends Context {
}
private static class CalledHandlers {
private static final class CalledHandlers {
private final List<ObservationHandler<?>> calledHandlers = new ArrayList<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -74,7 +74,7 @@ class ObservationRegistryConfigurerIntegrationTests {
}
private static class CalledCustomizers {
private static final class CalledCustomizers {
private final List<ObservationRegistryCustomizer<?>> customizers = new ArrayList<>();

View File

@ -140,7 +140,7 @@ class OpenTelemetryAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class UserConfiguration {
private static final class UserConfiguration {
@Bean
OpenTelemetry customOpenTelemetry() {

View File

@ -48,7 +48,7 @@ class OpenTelemetryPropertiesTests {
@Configuration(proxyBeanMethods = false)
@EnableConfigurationProperties(OpenTelemetryProperties.class)
private static class TestConfiguration {
private static final class TestConfiguration {
}

View File

@ -108,7 +108,7 @@ class R2dbcObservationAutoConfigurationTests {
return handler;
}
private static class CapturingObservationHandler implements ObservationHandler<Context> {
private static final class CapturingObservationHandler implements ObservationHandler<Context> {
private final AtomicReference<Context> context = new AtomicReference<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -443,7 +443,7 @@ class BraveAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
Tracing customTracing() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -162,7 +162,7 @@ class MicrometerTracingAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class TracerConfiguration {
private static final class TracerConfiguration {
@Bean
Tracer tracer() {
@ -172,7 +172,7 @@ class MicrometerTracingAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class PropagatorConfiguration {
private static final class PropagatorConfiguration {
@Bean
Propagator propagator() {
@ -182,7 +182,7 @@ class MicrometerTracingAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
DefaultTracingObservationHandler customDefaultTracingObservationHandler() {
@ -218,7 +218,7 @@ class MicrometerTracingAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class SpanTagAnnotationHandlerConfiguration {
private static final class SpanTagAnnotationHandlerConfiguration {
@Bean
SpanTagAnnotationHandler spanTagAnnotationHandler() {

View File

@ -65,7 +65,7 @@ class NoopTracerAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomTracerConfiguration {
private static final class CustomTracerConfiguration {
@Bean
Tracer customTracer() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -309,7 +309,7 @@ class OpenTelemetryAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class MeterProviderConfiguration {
private static final class MeterProviderConfiguration {
@Bean
MeterProvider meterProvider() {
@ -322,7 +322,7 @@ class OpenTelemetryAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class AdditionalSpanProcessorConfiguration {
private static final class AdditionalSpanProcessorConfiguration {
@Bean
SpanProcessor customSpanProcessor() {
@ -332,7 +332,7 @@ class OpenTelemetryAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class MultipleSpanExporterConfiguration {
private static final class MultipleSpanExporterConfiguration {
@Bean
SpanExporter spanExporter1() {
@ -347,7 +347,7 @@ class OpenTelemetryAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
SpanProcessors customSpanProcessors() {
@ -427,7 +427,7 @@ class OpenTelemetryAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class SdkTracerProviderCustomizationConfiguration {
private static final class SdkTracerProviderCustomizationConfiguration {
@Bean
@Order(1)
@ -449,7 +449,7 @@ class OpenTelemetryAutoConfigurationTests {
}
private static class DummySpanExporter implements SpanExporter {
private static final class DummySpanExporter implements SpanExporter {
@Override
public CompletableResultCode export(Collection<SpanData> spans) {
@ -469,7 +469,7 @@ class OpenTelemetryAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class InMemoryRecordingSpanExporterConfiguration {
private static final class InMemoryRecordingSpanExporterConfiguration {
@Bean
InMemoryRecordingSpanExporter spanExporter() {
@ -478,7 +478,7 @@ class OpenTelemetryAutoConfigurationTests {
}
private static class InMemoryRecordingSpanExporter implements SpanExporter {
private static final class InMemoryRecordingSpanExporter implements SpanExporter {
private final List<SpanData> exportedSpans = new ArrayList<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -127,7 +127,7 @@ class OtlpAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomHttpExporterConfiguration {
private static final class CustomHttpExporterConfiguration {
@Bean
OtlpHttpSpanExporter customOtlpHttpSpanExporter() {
@ -137,7 +137,7 @@ class OtlpAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomGrpcExporterConfiguration {
private static final class CustomGrpcExporterConfiguration {
@Bean
OtlpGrpcSpanExporter customOtlpGrpcSpanExporter() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -116,7 +116,7 @@ class PrometheusExemplarsAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
static final SpanContextSupplier SUPPLIER = mock(SpanContextSupplier.class);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -173,7 +173,7 @@ class WavefrontTracingAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
ApplicationTags customApplicationTags() {
@ -203,7 +203,7 @@ class WavefrontTracingAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class WavefrontSenderConfiguration {
private static final class WavefrontSenderConfiguration {
@Bean
WavefrontSender wavefrontSender() {
@ -213,7 +213,7 @@ class WavefrontTracingAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class MeterRegistryConfiguration {
private static final class MeterRegistryConfiguration {
@Bean
MeterRegistry meterRegistry() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -87,7 +87,7 @@ class ZipkinAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
BytesEncoder<Span> customBytesEncoder() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -89,7 +89,7 @@ class ZipkinConfigurationsBraveConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class ReporterConfiguration {
private static final class ReporterConfiguration {
@Bean
@SuppressWarnings("unchecked")
@ -100,7 +100,7 @@ class ZipkinConfigurationsBraveConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
@SuppressWarnings("unchecked")
@ -111,7 +111,7 @@ class ZipkinConfigurationsBraveConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomSpanHandlerConfiguration {
private static final class CustomSpanHandlerConfiguration {
@Bean
SpanHandler customSpanHandler() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -80,7 +80,7 @@ class ZipkinConfigurationsOpenTelemetryConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class SenderConfiguration {
private static final class SenderConfiguration {
@Bean
Sender sender() {
@ -90,7 +90,7 @@ class ZipkinConfigurationsOpenTelemetryConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
ZipkinSpanExporter customZipkinSpanExporter() {
@ -100,7 +100,7 @@ class ZipkinConfigurationsOpenTelemetryConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class BaseConfiguration {
private static final class BaseConfiguration {
@Bean
@ConditionalOnMissingBean

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -64,7 +64,7 @@ class ZipkinConfigurationsReporterConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class SenderConfiguration {
private static final class SenderConfiguration {
@Bean
Sender sender() {
@ -74,7 +74,7 @@ class ZipkinConfigurationsReporterConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
@SuppressWarnings("unchecked")
@ -85,7 +85,7 @@ class ZipkinConfigurationsReporterConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class BaseConfiguration {
private static final class BaseConfiguration {
@Bean
@ConditionalOnMissingBean

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -173,7 +173,7 @@ class ZipkinConfigurationsSenderConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class RestTemplateConfiguration {
private static final class RestTemplateConfiguration {
@Bean
ZipkinRestTemplateBuilderCustomizer zipkinRestTemplateBuilderCustomizer() {
@ -183,7 +183,7 @@ class ZipkinConfigurationsSenderConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class WebClientConfiguration {
private static final class WebClientConfiguration {
@Bean
ZipkinWebClientBuilderCustomizer webClientBuilder() {
@ -193,7 +193,7 @@ class ZipkinConfigurationsSenderConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomConfiguration {
private static final class CustomConfiguration {
@Bean
Sender customSender() {
@ -202,7 +202,7 @@ class ZipkinConfigurationsSenderConfigurationTests {
}
private static class DummyZipkinRestTemplateBuilderCustomizer implements ZipkinRestTemplateBuilderCustomizer {
private static final class DummyZipkinRestTemplateBuilderCustomizer implements ZipkinRestTemplateBuilderCustomizer {
@Override
public RestTemplateBuilder customize(RestTemplateBuilder restTemplateBuilder) {

View File

@ -187,7 +187,7 @@ class ZipkinWebClientSenderTests extends ZipkinHttpSenderTests {
dispatcher.clear();
}
private static class ClearableDispatcher extends QueueDispatcher {
private static final class ClearableDispatcher extends QueueDispatcher {
void clear() {
getResponseQueue().clear();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -402,7 +402,7 @@ public class ConfigurationPropertiesReportEndpoint implements ApplicationContext
* Extension to {@link JacksonAnnotationIntrospector} to suppress CGLIB generated bean
* properties.
*/
private static class ConfigurationPropertiesAnnotationIntrospector extends JacksonAnnotationIntrospector {
private static final class ConfigurationPropertiesAnnotationIntrospector extends JacksonAnnotationIntrospector {
@Override
public Object findFilterId(Annotated a) {
@ -425,7 +425,7 @@ public class ConfigurationPropertiesReportEndpoint implements ApplicationContext
* <li>Properties that throw an exception when retrieving their value.
* </ul>
*/
private static class ConfigurationPropertiesPropertyFilter extends SimpleBeanPropertyFilter {
private static final class ConfigurationPropertiesPropertyFilter extends SimpleBeanPropertyFilter {
private static final Log logger = LogFactory.getLog(ConfigurationPropertiesPropertyFilter.class);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -81,7 +81,7 @@ class OperationMethodParameter implements OperationParameter {
return this.name + " of type " + this.parameter.getType().getName();
}
private static class Jsr305 {
private static final class Jsr305 {
boolean isMandatory(Parameter parameter) {
MergedAnnotation<Nonnull> annotation = MergedAnnotations.from(parameter).get(Nonnull.class);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -172,7 +172,7 @@ public class EndpointMBean implements DynamicMBean {
return new AttributeList();
}
private static class ReactiveHandler {
private static final class ReactiveHandler {
static Object handle(Object result) {
if (result instanceof Flux) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -182,7 +182,7 @@ class DiscoveredJmxOperation extends AbstractDiscoveredOperation implements JmxO
/**
* Utility to convert to JMX supported types.
*/
private static class JmxType {
private static final class JmxType {
static Class<?> get(Class<?> source) {
if (source.isEnum()) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -397,7 +397,7 @@ public abstract class AbstractWebMvcEndpointHandlerMapping extends RequestMappin
return body;
}
private static class FluxBodyConverter implements Function<Object, Object> {
private static final class FluxBodyConverter implements Function<Object, Object> {
@Override
public Object apply(Object body) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -100,7 +100,7 @@ public class SimpleStatusAggregator implements StatusAggregator {
/**
* {@link Comparator} used to order {@link Status}.
*/
private class StatusComparator implements Comparator<Status> {
private final class StatusComparator implements Comparator<Status> {
@Override
public int compare(Status s1, Status s2) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -163,7 +163,7 @@ public class DataSourceHealthIndicator extends AbstractHealthIndicator implement
/**
* {@link RowMapper} that expects and returns results from a single column.
*/
private static class SingleColumnRowMapper implements RowMapper<Object> {
private static final class SingleColumnRowMapper implements RowMapper<Object> {
@Override
public Object mapRow(ResultSet rs, int rowNum) throws SQLException {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -51,7 +51,7 @@ public class LdapHealthIndicator extends AbstractHealthIndicator {
builder.up().withDetail("version", version);
}
private static class VersionContextExecutor implements ContextExecutor<String> {
private static final class VersionContextExecutor implements ContextExecutor<String> {
@Override
public String executeWithContext(DirContext ctx) throws NamingException {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -96,7 +96,7 @@ public class CacheMetricsRegistrar {
return cache;
}
private static class TransactionAwareCacheDecoratorHandler {
private static final class TransactionAwareCacheDecoratorHandler {
private static Cache unwrapIfNecessary(Cache cache) {
try {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -88,7 +88,7 @@ public final class Neo4jReactiveHealthIndicator extends AbstractReactiveHealthIn
* Builder used to create a {@link Neo4jHealthDetails} from a {@link Record} and a
* {@link ResultSummary}.
*/
private static class Neo4jHealthDetailsBuilder {
private static final class Neo4jHealthDetailsBuilder {
private Record record;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -93,7 +93,7 @@ public class AuthenticationAuditListener extends AbstractAuthenticationAuditList
publish(new AuditEvent(event.getAuthentication().getName(), AUTHENTICATION_SUCCESS, data));
}
private static class WebAuditListener {
private static final class WebAuditListener {
void process(AuthenticationAuditListener listener, AbstractAuthenticationEvent input) {
if (listener != null) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -95,7 +95,7 @@ class OperationReflectiveProcessorTests {
}
@SuppressWarnings("unused")
private static class Methods {
private static final class Methods {
private String string() {
return null;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -261,7 +261,7 @@ class CachingOperationInvokerTests {
then(target).should(times(1)).invoke(contextManagement);
}
private static class MonoOperationInvoker implements OperationInvoker {
private static final class MonoOperationInvoker implements OperationInvoker {
static AtomicInteger invocations = new AtomicInteger();
@ -275,7 +275,7 @@ class CachingOperationInvokerTests {
}
private static class FluxOperationInvoker implements OperationInvoker {
private static final class FluxOperationInvoker implements OperationInvoker {
static AtomicInteger invocations = new AtomicInteger();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -390,7 +390,7 @@ public class AutoConfigurationImportSelector implements DeferredImportSelector,
}
private static class AutoConfigurationGroup
private static final class AutoConfigurationGroup
implements DeferredImportSelector.Group, BeanClassLoaderAware, BeanFactoryAware, ResourceLoaderAware {
private final Map<String, AnnotationMetadata> entries = new LinkedHashMap<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -139,7 +139,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
/**
* Early initializer for Spring MessageConverters.
*/
private static class MessageConverterInitializer implements Runnable {
private static final class MessageConverterInitializer implements Runnable {
@Override
public void run() {
@ -151,7 +151,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
/**
* Early initializer for jakarta.validation.
*/
private static class ValidationInitializer implements Runnable {
private static final class ValidationInitializer implements Runnable {
@Override
public void run() {
@ -164,7 +164,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
/**
* Early initializer for Jackson.
*/
private static class JacksonInitializer implements Runnable {
private static final class JacksonInitializer implements Runnable {
@Override
public void run() {
@ -176,7 +176,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
/**
* Early initializer for Spring's ConversionService.
*/
private static class ConversionServiceInitializer implements Runnable {
private static final class ConversionServiceInitializer implements Runnable {
@Override
public void run() {
@ -185,7 +185,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
}
private static class CharsetInitializer implements Runnable {
private static final class CharsetInitializer implements Runnable {
@Override
public void run() {
@ -194,7 +194,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
}
private static class TomcatInitializer implements Runnable {
private static final class TomcatInitializer implements Runnable {
@Override
public void run() {
@ -204,7 +204,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
}
private static class JdkInitializer implements Runnable {
private static final class JdkInitializer implements Runnable {
@Override
public void run() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -277,7 +277,7 @@ public class CassandraAutoConfiguration {
return connectionDetails.getContactPoints().stream().map((node) -> node.host() + ":" + node.port()).toList();
}
private static class CassandraDriverOptions {
private static final class CassandraDriverOptions {
private final Map<String, String> options = new LinkedHashMap<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -291,7 +291,7 @@ public final class ConditionEvaluationReport {
}
private static class AncestorsMatchedCondition implements Condition {
private static final class AncestorsMatchedCondition implements Condition {
@Override
public boolean matches(ConditionContext context, AnnotatedTypeMetadata metadata) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class CassandraReactiveRepositoriesRegistrar extends AbstractRepositoryConfigura
}
@EnableReactiveCassandraRepositories
private static class EnableReactiveCassandraRepositoriesConfiguration {
private static final class EnableReactiveCassandraRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class CassandraRepositoriesRegistrar extends AbstractRepositoryConfigurationSour
}
@EnableCassandraRepositories
private static class EnableCassandraRepositoriesConfiguration {
private static final class EnableCassandraRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class CouchbaseReactiveRepositoriesRegistrar extends AbstractRepositoryConfigura
}
@EnableReactiveCouchbaseRepositories
private static class EnableReactiveCouchbaseRepositoriesConfiguration {
private static final class EnableReactiveCouchbaseRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class CouchbaseRepositoriesRegistrar extends AbstractRepositoryConfigurationSour
}
@EnableCouchbaseRepositories
private static class EnableCouchbaseRepositoriesConfiguration {
private static final class EnableCouchbaseRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -49,7 +49,7 @@ class ElasticsearchRepositoriesRegistrar extends AbstractRepositoryConfiguration
}
@EnableElasticsearchRepositories
private static class EnableElasticsearchRepositoriesConfiguration {
private static final class EnableElasticsearchRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class ReactiveElasticsearchRepositoriesRegistrar extends AbstractRepositoryConfi
}
@EnableReactiveElasticsearchRepositories
private static class EnableElasticsearchRepositoriesConfiguration {
private static final class EnableElasticsearchRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class JdbcRepositoriesRegistrar extends AbstractRepositoryConfigurationSourceSup
}
@EnableJdbcRepositories
private static class EnableJdbcRepositoriesConfiguration {
private static final class EnableJdbcRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2021 the original author or authors.
* Copyright 2012-2024 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.
@ -34,7 +34,7 @@ class EnversRevisionRepositoriesRegistrar extends JpaRepositoriesRegistrar {
}
@EnableJpaRepositories(repositoryFactoryBeanClass = EnversRevisionRepositoryFactoryBean.class)
private static class EnableJpaRepositoriesConfiguration {
private static final class EnableJpaRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2024 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.
@ -74,7 +74,7 @@ class JpaRepositoriesRegistrar extends AbstractRepositoryConfigurationSourceSupp
}
@EnableJpaRepositories
private static class EnableJpaRepositoriesConfiguration {
private static final class EnableJpaRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class LdapRepositoriesRegistrar extends AbstractRepositoryConfigurationSourceSup
}
@EnableLdapRepositories
private static class EnableLdapRepositoriesConfiguration {
private static final class EnableLdapRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class MongoReactiveRepositoriesRegistrar extends AbstractRepositoryConfiguration
}
@EnableReactiveMongoRepositories
private static class EnableReactiveMongoRepositoriesConfiguration {
private static final class EnableReactiveMongoRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class MongoRepositoriesRegistrar extends AbstractRepositoryConfigurationSourceSu
}
@EnableMongoRepositories
private static class EnableMongoRepositoriesConfiguration {
private static final class EnableMongoRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class Neo4jReactiveRepositoriesRegistrar extends AbstractRepositoryConfiguration
}
@EnableReactiveNeo4jRepositories
private static class EnableReactiveNeo4jRepositoriesConfiguration {
private static final class EnableReactiveNeo4jRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class Neo4jRepositoriesRegistrar extends AbstractRepositoryConfigurationSourceSu
}
@EnableNeo4jRepositories
private static class EnableNeo4jRepositoriesConfiguration {
private static final class EnableNeo4jRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class R2dbcRepositoriesAutoConfigureRegistrar extends AbstractRepositoryConfigur
}
@EnableR2dbcRepositories
private static class EnableR2dbcRepositoriesConfiguration {
private static final class EnableR2dbcRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -212,7 +212,7 @@ class LettuceConnectionConfiguration extends RedisConnectionConfiguration {
/**
* Inner class to allow optional commons-pool2 dependency.
*/
private static class PoolBuilderFactory {
private static final class PoolBuilderFactory {
LettuceClientConfigurationBuilder createBuilder(Pool properties) {
return LettucePoolingClientConfiguration.builder().poolConfig(getPoolConfig(properties));

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -48,7 +48,7 @@ class RedisRepositoriesRegistrar extends AbstractRepositoryConfigurationSourceSu
}
@EnableRedisRepositories
private static class EnableRedisRepositoriesConfiguration {
private static final class EnableRedisRepositoriesConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -94,7 +94,7 @@ public class HttpMessageConvertersAutoConfiguration {
}
@ConditionalOnWebApplication(type = Type.REACTIVE)
private static class ReactiveWebApplication {
private static final class ReactiveWebApplication {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -59,7 +59,7 @@ class IntegrationAutoConfigurationScanRegistrar extends IntegrationComponentScan
}
@IntegrationComponentScan
private static class IntegrationComponentScanConfiguration {
private static final class IntegrationComponentScanConfiguration {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -1757,7 +1757,7 @@ public class KafkaProperties {
}
@SuppressWarnings("serial")
private static class Properties extends HashMap<String, Object> {
private static final class Properties extends HashMap<String, Object> {
<V> java.util.function.Consumer<V> in(String key) {
return (value) -> put(key, value);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -153,7 +153,7 @@ public class TemplateAvailabilityProviders {
return null;
}
private static class NoTemplateAvailabilityProvider implements TemplateAvailabilityProvider {
private static final class NoTemplateAvailabilityProvider implements TemplateAvailabilityProvider {
@Override
public boolean isTemplateAvailable(String view, Environment environment, ClassLoader classLoader,

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -33,7 +33,7 @@ class NotReactiveWebApplicationCondition extends NoneNestedConditions {
}
@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.REACTIVE)
private static class ReactiveWebApplication {
private static final class ReactiveWebApplication {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -330,7 +330,7 @@ public abstract class AbstractErrorWebExceptionHandler implements ErrorWebExcept
return response.writeTo(exchange, new ResponseContext());
}
private class ResponseContext implements ServerResponse.Context {
private final class ResponseContext implements ServerResponse.Context {
@Override
public List<HttpMessageWriter<?>> messageWriters() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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 @@ public class DispatcherServletAutoConfiguration {
}
@Order(Ordered.LOWEST_PRECEDENCE - 10)
private static class DefaultDispatcherServletCondition extends SpringBootCondition {
private static final class DefaultDispatcherServletCondition extends SpringBootCondition {
@Override
public ConditionOutcome getMatchOutcome(ConditionContext context, AnnotatedTypeMetadata metadata) {
@ -160,7 +160,7 @@ public class DispatcherServletAutoConfiguration {
}
@Order(Ordered.LOWEST_PRECEDENCE - 10)
private static class DispatcherServletRegistrationCondition extends SpringBootCondition {
private static final class DispatcherServletRegistrationCondition extends SpringBootCondition {
@Override
public ConditionOutcome getMatchOutcome(ConditionContext context, AnnotatedTypeMetadata metadata) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -169,7 +169,7 @@ public class ErrorMvcAutoConfiguration {
/**
* {@link SpringBootCondition} that matches when no error template view is detected.
*/
private static class ErrorTemplateMissingCondition extends SpringBootCondition {
private static final class ErrorTemplateMissingCondition extends SpringBootCondition {
@Override
public ConditionOutcome getMatchOutcome(ConditionContext context, AnnotatedTypeMetadata metadata) {
@ -188,7 +188,7 @@ public class ErrorMvcAutoConfiguration {
/**
* Simple {@link View} implementation that writes a default HTML error page.
*/
private static class StaticView implements View {
private static final class StaticView implements View {
private static final MediaType TEXT_HTML_UTF8 = new MediaType("text", "html", StandardCharsets.UTF_8);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -44,7 +44,7 @@ public class UndertowWebSocketServletWebServerCustomizer
return 0;
}
private static class WebsocketDeploymentInfoCustomizer implements UndertowDeploymentInfoCustomizer {
private static final class WebsocketDeploymentInfoCustomizer implements UndertowDeploymentInfoCustomizer {
@Override
public void customize(DeploymentInfo deploymentInfo) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -216,7 +216,7 @@ class AutoConfigurationImportSelectorTests {
return ImportCandidates.load(AutoConfiguration.class, getClass().getClassLoader()).getCandidates();
}
private class TestAutoConfigurationImportSelector extends AutoConfigurationImportSelector {
private final class TestAutoConfigurationImportSelector extends AutoConfigurationImportSelector {
private AutoConfigurationImportEvent lastEvent;
@ -269,54 +269,54 @@ class AutoConfigurationImportSelectorTests {
}
@Configuration(proxyBeanMethods = false)
private class TestConfiguration {
private final class TestConfiguration {
}
@EnableAutoConfiguration
private class BasicEnableAutoConfiguration {
private final class BasicEnableAutoConfiguration {
}
@EnableAutoConfiguration(exclude = FreeMarkerAutoConfiguration.class)
private class EnableAutoConfigurationWithClassExclusions {
private final class EnableAutoConfigurationWithClassExclusions {
}
@SpringBootApplication(exclude = FreeMarkerAutoConfiguration.class)
private class SpringBootApplicationWithClassExclusions {
private final class SpringBootApplicationWithClassExclusions {
}
@EnableAutoConfiguration(excludeName = "org.springframework.boot.autoconfigure.mustache.MustacheAutoConfiguration")
private class EnableAutoConfigurationWithClassNameExclusions {
private final class EnableAutoConfigurationWithClassNameExclusions {
}
@EnableAutoConfiguration(exclude = MustacheAutoConfiguration.class,
excludeName = "org.springframework.boot.autoconfigure.freemarker.FreeMarkerAutoConfiguration")
private class EnableAutoConfigurationWithClassAndClassNameExclusions {
private final class EnableAutoConfigurationWithClassAndClassNameExclusions {
}
@EnableAutoConfiguration(exclude = TestConfiguration.class)
private class EnableAutoConfigurationWithFaultyClassExclude {
private final class EnableAutoConfigurationWithFaultyClassExclude {
}
@EnableAutoConfiguration(
excludeName = "org.springframework.boot.autoconfigure.AutoConfigurationImportSelectorTests.TestConfiguration")
private class EnableAutoConfigurationWithFaultyClassNameExclude {
private final class EnableAutoConfigurationWithFaultyClassNameExclude {
}
@EnableAutoConfiguration(excludeName = "org.springframework.boot.autoconfigure.DoesNotExist1")
private class EnableAutoConfigurationWithAbsentClassNameExclude {
private final class EnableAutoConfigurationWithAbsentClassNameExclude {
}
@SpringBootApplication(excludeName = "org.springframework.boot.autoconfigure.mustache.MustacheAutoConfiguration")
private class SpringBootApplicationWithClassNameExclusions {
private final class SpringBootApplicationWithClassNameExclusions {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -405,7 +405,7 @@ class R2dbcAutoConfigurationTests {
}
@Configuration(proxyBeanMethods = false)
private static class CustomizerConfiguration {
private static final class CustomizerConfiguration {
@Bean
ConnectionFactoryOptionsBuilderCustomizer customizer() {

View File

@ -165,7 +165,7 @@ class FileWatcherTests {
}
}
private static class WaitingCallback implements Runnable {
private static final class WaitingCallback implements Runnable {
private final CountDownLatch latch = new CountDownLatch(1);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2021 the original author or authors.
* Copyright 2012-2024 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.
@ -52,7 +52,7 @@ class ScheduledBeanLazyInitializationExcludeFilterTests {
return this.filter.isExcluded("test", new RootBeanDefinition(type), type);
}
private static class TestBean {
private static final class TestBean {
@Scheduled
void doStuff() {
@ -60,7 +60,7 @@ class ScheduledBeanLazyInitializationExcludeFilterTests {
}
private static class AnotherTestBean {
private static final class AnotherTestBean {
@Schedules({ @Scheduled(fixedRate = 5000), @Scheduled(fixedRate = 2500) })
void doStuff() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -298,7 +298,7 @@ public class LiveReloadServer {
/**
* {@link ThreadFactory} to create the worker threads.
*/
private static class WorkerThreadFactory implements ThreadFactory {
private static final class WorkerThreadFactory implements ThreadFactory {
private final AtomicInteger threadNumber = new AtomicInteger(1);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -212,7 +212,7 @@ final class ClassLoaderFilesResourcePatternResolver implements ResourcePatternRe
* {@link ResourcePatternResolverFactory} to be used when the classloader can access
* {@link WebApplicationContext}.
*/
private static class WebResourcePatternResolverFactory extends ResourcePatternResolverFactory {
private static final class WebResourcePatternResolverFactory extends ResourcePatternResolverFactory {
@Override
public ResourcePatternResolver getResourcePatternResolver(AbstractApplicationContext applicationContext,

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -37,7 +37,7 @@ public class RestartScopeInitializer implements ApplicationContextInitializer<Co
/**
* {@link Scope} that stores beans as {@link Restarter} attributes.
*/
private static class RestartScope implements Scope {
private static final class RestartScope implements Scope {
@Override
public Object get(String name, ObjectFactory<?> objectFactory) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -617,7 +617,7 @@ public class Restarter {
/**
* {@link ThreadFactory} that creates a leak safe thread.
*/
private class LeakSafeThreadFactory implements ThreadFactory {
private final class LeakSafeThreadFactory implements ThreadFactory {
@Override
public Thread newThread(Runnable runnable) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -92,7 +92,7 @@ class SilentExitExceptionHandler implements UncaughtExceptionHandler {
throw new SilentExitException();
}
private static class SilentExitException extends RuntimeException {
private static final class SilentExitException extends RuntimeException {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -186,7 +186,7 @@ class DevToolsR2dbcAutoConfigurationTests {
}
private static class MockConnectionFactory implements ConnectionFactory {
private static final class MockConnectionFactory implements ConnectionFactory {
@Override
public Publisher<? extends Connection> create() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -326,7 +326,7 @@ class FileSystemWatcherTests {
return file;
}
private static class TestSnapshotStateRepository implements SnapshotStateRepository {
private static final class TestSnapshotStateRepository implements SnapshotStateRepository {
private Object state;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -127,7 +127,7 @@ class RestartApplicationListenerTests {
}
}
private static class ImplicitlyEnabledRestartApplicationListener extends RestartApplicationListener {
private static final class ImplicitlyEnabledRestartApplicationListener extends RestartApplicationListener {
@Override
boolean implicitlyEnableRestart() {

View File

@ -34,7 +34,7 @@ import org.springframework.web.bind.annotation.RestController;
public class MySpringBootTestsConfiguration {
@RestController
private static class ExampleController {
private static final class ExampleController {
@RequestMapping("/example")
ResponseEntity<String> example() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2024 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.
@ -51,7 +51,7 @@ class OverrideAutoConfigurationContextCustomizerFactory implements ContextCustom
/**
* {@link ContextCustomizer} to disable full auto-configuration.
*/
private static class DisableAutoConfigurationContextCustomizer implements ContextCustomizer {
private static final class DisableAutoConfigurationContextCustomizer implements ContextCustomizer {
@Override
public void customizeContext(ConfigurableApplicationContext context, MergedContextConfiguration mergedConfig) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -56,7 +56,7 @@ public class RestDocsTestExecutionListener extends AbstractTestExecutionListener
}
}
private static class DocumentationHandler {
private static final class DocumentationHandler {
private void beforeTestMethod(TestContext testContext) {
ManualRestDocumentation restDocumentation = findManualRestDocumentation(testContext);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -173,7 +173,7 @@ public class SpringBootMockMvcBuilderCustomizer implements MockMvcBuilderCustomi
writer.write(((Printer) getPrinter()).getLines());
}
private static class Printer implements ResultValuePrinter {
private static final class Printer implements ResultValuePrinter {
private final List<String> lines = new ArrayList<>();
@ -257,7 +257,7 @@ public class SpringBootMockMvcBuilderCustomizer implements MockMvcBuilderCustomi
/**
* {@link LinesWriter} to output results to the log.
*/
private static class LoggingLinesWriter implements LinesWriter {
private static final class LoggingLinesWriter implements LinesWriter {
private static final Log logger = LogFactory.getLog("org.springframework.test.web.servlet.result");
@ -314,7 +314,7 @@ public class SpringBootMockMvcBuilderCustomizer implements MockMvcBuilderCustomi
addAsRegistrationBean(beanFactory, Filter.class, new FilterRegistrationBeanAdapter());
}
private static class FilterRegistrationBeanAdapter implements RegistrationBeanAdapter<Filter> {
private static final class FilterRegistrationBeanAdapter implements RegistrationBeanAdapter<Filter> {
@Override
public RegistrationBean createRegistrationBean(String name, Filter source, int totalNumberOfSourceBeans) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -380,7 +380,7 @@ public class SpringBootContextLoader extends AbstractContextLoader implements Ao
/**
* Inner class to configure {@link WebMergedContextConfiguration}.
*/
private static class WebConfigurer {
private static final class WebConfigurer {
void configure(MergedContextConfiguration mergedConfig, List<ApplicationContextInitializer<?>> initializers) {
WebMergedContextConfiguration webMergedConfig = (WebMergedContextConfiguration) mergedConfig;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2024 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.
@ -44,7 +44,7 @@ class DuplicateJsonObjectContextCustomizerFactory implements ContextCustomizerFa
return new DuplicateJsonObjectContextCustomizer();
}
private static class DuplicateJsonObjectContextCustomizer implements ContextCustomizer {
private static final class DuplicateJsonObjectContextCustomizer implements ContextCustomizer {
private final Log logger = LogFactory.getLog(DuplicateJsonObjectContextCustomizer.class);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -121,7 +121,7 @@ public class MockitoTestExecutionListener extends AbstractTestExecutionListener
/**
* {@link FieldCallback} to collect Mockito annotations.
*/
private static class MockitoAnnotationCollection implements FieldCallback {
private static final class MockitoAnnotationCollection implements FieldCallback {
private final Set<Annotation> annotations = new LinkedHashSet<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -1077,7 +1077,7 @@ public class TestRestTemplate {
}
private static class NoOpResponseErrorHandler extends DefaultResponseErrorHandler {
private static final class NoOpResponseErrorHandler extends DefaultResponseErrorHandler {
@Override
public void handleError(ClientHttpResponse response) throws IOException {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -474,7 +474,8 @@ class SpringBootContextLoaderTests {
}
private static class ContextLoaderApplicationContextFailureProcessor implements ApplicationContextFailureProcessor {
private static final class ContextLoaderApplicationContextFailureProcessor
implements ApplicationContextFailureProcessor {
static ApplicationContext failedContext;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -54,7 +54,7 @@ class SpringBootMockResolverTests {
}
private static class MyServiceImpl implements MyService {
private static final class MyServiceImpl implements MyService {
@Override
public int a() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2021 the original author or authors.
* Copyright 2012-2024 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.
@ -45,7 +45,7 @@ class WebTestClientContextCustomizerWithoutWebfluxIntegrationTests {
}
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
private static class TestClass {
private static final class TestClass {
}

View File

@ -93,7 +93,7 @@ class TestcontainersStartupTests {
return testStartables;
}
private class TestStartable implements Startable {
private final class TestStartable implements Startable {
private int index;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -101,7 +101,7 @@ final class BuildpackLayersMetadata extends MappedObject {
return new BuildpackLayersMetadata(node);
}
private static class Buildpacks {
private static final class Buildpacks {
private final Map<String, BuildpackVersions> buildpacks = new HashMap<>();
@ -126,7 +126,7 @@ final class BuildpackLayersMetadata extends MappedObject {
}
private static class BuildpackVersions {
private static final class BuildpackVersions {
private final Map<String, BuildpackLayerDetails> versions = new HashMap<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -331,7 +331,7 @@ class Lifecycle implements Closeable {
/**
* Common directories used by the various phases.
*/
private static class Directory {
private static final class Directory {
/**
* The directory used by buildpacks to write their layer contributions. A new

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -500,7 +500,7 @@ public class DockerApi {
/**
* {@link UpdateListener} used to capture the image digest.
*/
private static class DigestCaptureUpdateListener implements UpdateListener<ProgressUpdateEvent> {
private static final class DigestCaptureUpdateListener implements UpdateListener<ProgressUpdateEvent> {
private static final String PREFIX = "Digest:";
@ -521,7 +521,7 @@ public class DockerApi {
/**
* {@link UpdateListener} used to ensure an image load response stream.
*/
private static class StreamCaptureUpdateListener implements UpdateListener<LoadImageUpdateEvent> {
private static final class StreamCaptureUpdateListener implements UpdateListener<LoadImageUpdateEvent> {
private String stream;
@ -540,7 +540,7 @@ public class DockerApi {
* {@link UpdateListener} used to capture the details of an error in a response
* stream.
*/
private static class ErrorCaptureUpdateListener implements UpdateListener<PushImageUpdateEvent> {
private static final class ErrorCaptureUpdateListener implements UpdateListener<PushImageUpdateEvent> {
@Override
public void onUpdate(PushImageUpdateEvent event) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -88,7 +88,7 @@ final class LocalHttpClientTransport extends HttpClientTransport {
/**
* {@link DnsResolver} that ensures only the loopback address is used.
*/
private static class LocalDnsResolver implements DnsResolver {
private static final class LocalDnsResolver implements DnsResolver {
private static final InetAddress LOOPBACK = InetAddress.getLoopbackAddress();
@ -136,7 +136,7 @@ final class LocalHttpClientTransport extends HttpClientTransport {
/**
* {@link HttpRoutePlanner} for local Docker.
*/
private static class LocalRoutePlanner implements HttpRoutePlanner {
private static final class LocalRoutePlanner implements HttpRoutePlanner {
@Override
public HttpRoute determineRoute(HttpHost target, HttpContext context) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2023 the original author or authors.
* Copyright 2012-2024 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.
@ -157,7 +157,7 @@ public abstract class DomainSocket extends AbstractSocket {
/**
* {@link InputStream} returned from the {@link DomainSocket}.
*/
private class DomainSocketInputStream extends InputStream {
private final class DomainSocketInputStream extends InputStream {
@Override
public int read() throws IOException {
@ -180,7 +180,7 @@ public abstract class DomainSocket extends AbstractSocket {
/**
* {@link OutputStream} returned from the {@link DomainSocket}.
*/
private class DomainSocketOutputStream extends OutputStream {
private final class DomainSocketOutputStream extends OutputStream {
@Override
public void write(int b) throws IOException {

Some files were not shown because too many files have changed in this diff Show More