Skip to content

Commit 322191f

Browse files
committed
Merge branch '3.3.x' into 3.4.x
Closes gh-44684
2 parents cb49df3 + 0900245 commit 322191f

File tree

8 files changed

+15
-19
lines changed

8 files changed

+15
-19
lines changed

spring-boot-project/spring-boot-actuator-autoconfigure/src/main/java/org/springframework/boot/actuate/autoconfigure/data/redis/RedisReactiveHealthContributorAutoConfiguration.java

+1-4
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616

1717
package org.springframework.boot.actuate.autoconfigure.data.redis;
1818

19-
import java.util.Map;
20-
2119
import reactor.core.publisher.Flux;
2220

2321
import org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
@@ -51,8 +49,7 @@
5149
public class RedisReactiveHealthContributorAutoConfiguration extends
5250
CompositeReactiveHealthContributorConfiguration<RedisReactiveHealthIndicator, ReactiveRedisConnectionFactory> {
5351

54-
RedisReactiveHealthContributorAutoConfiguration(
55-
Map<String, ReactiveRedisConnectionFactory> redisConnectionFactories) {
52+
RedisReactiveHealthContributorAutoConfiguration() {
5653
super(RedisReactiveHealthIndicator::new);
5754
}
5855

spring-boot-project/spring-boot-actuator-autoconfigure/src/test/java/org/springframework/boot/actuate/autoconfigure/health/AbstractCompositeHealthContributorConfigurationTests.java

-3
Original file line numberDiff line numberDiff line change
@@ -123,13 +123,11 @@ TestBean standard() {
123123
@Bean(defaultCandidate = false)
124124
TestBean nonDefault() {
125125
return new TestBean();
126-
127126
}
128127

129128
@Bean(autowireCandidate = false)
130129
TestBean nonAutowire() {
131130
return new TestBean();
132-
133131
}
134132

135133
}
@@ -145,7 +143,6 @@ TestBean standard() {
145143
@Bean(autowireCandidate = false)
146144
TestBean nonAutowire() {
147145
return new TestBean();
148-
149146
}
150147

151148
}

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/AutoConfigureBefore.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
public @interface AutoConfigureBefore {
4545

4646
/**
47-
* The auto-configure classes that should have not yet been applied.
47+
* The auto-configuration classes that should have not yet been applied.
4848
* @return the classes
4949
*/
5050
Class<?>[] value() default {};

spring-boot-project/spring-boot/src/main/java/org/springframework/boot/logging/log4j2/Log4J2LoggingSystem.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ public void cleanUp() {
447447
super.cleanUp();
448448
LoggerContext loggerContext = getLoggerContext();
449449
markAsUninitialized(loggerContext);
450-
StatusConsoleListener listener = (StatusConsoleListener) getLoggerContext().getObject(STATUS_LISTENER_KEY);
450+
StatusConsoleListener listener = (StatusConsoleListener) loggerContext.getObject(STATUS_LISTENER_KEY);
451451
if (listener != null) {
452452
StatusLogger.getLogger().removeListener(listener);
453453
loggerContext.removeObject(STATUS_LISTENER_KEY);

spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/servlet/context/ServletWebServerApplicationContext.java

+6-6
Original file line numberDiff line numberDiff line change
@@ -146,15 +146,15 @@ public final void refresh() throws BeansException, IllegalStateException {
146146
super.refresh();
147147
}
148148
catch (RuntimeException ex) {
149-
try {
150-
WebServer webServer = this.webServer;
151-
if (webServer != null) {
149+
WebServer webServer = this.webServer;
150+
if (webServer != null) {
151+
try {
152152
webServer.stop();
153153
webServer.destroy();
154154
}
155-
}
156-
catch (RuntimeException stopOrDestroyEx) {
157-
ex.addSuppressed(stopOrDestroyEx);
155+
catch (RuntimeException stopOrDestroyEx) {
156+
ex.addSuppressed(stopOrDestroyEx);
157+
}
158158
}
159159
throw ex;
160160
}

spring-boot-project/spring-boot/src/test/java/org/springframework/boot/web/reactive/context/ReactiveWebServerApplicationContextTests.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
import static org.assertj.core.api.Assertions.assertThatIllegalStateException;
4545
import static org.mockito.BDDMockito.then;
4646
import static org.mockito.BDDMockito.willThrow;
47+
import static org.mockito.Mockito.never;
4748
import static org.mockito.Mockito.times;
4849

4950
/**
@@ -148,7 +149,7 @@ void whenContextRefreshFailedThenWebServerStopFailedCatchStopException() {
148149
.withStackTraceContaining("WebServer has failed to stop");
149150
WebServer webServer = this.context.getWebServer();
150151
then(webServer).should().stop();
151-
then(webServer).should(times(0)).destroy();
152+
then(webServer).should(never()).destroy();
152153
}
153154

154155
@Test

spring-boot-project/spring-boot/src/test/java/org/springframework/boot/web/servlet/context/ServletWebServerApplicationContextTests.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@
8686
import static org.mockito.Mockito.atMost;
8787
import static org.mockito.Mockito.inOrder;
8888
import static org.mockito.Mockito.mock;
89+
import static org.mockito.Mockito.never;
8990
import static org.mockito.Mockito.times;
9091
import static org.mockito.Mockito.withSettings;
9192

@@ -236,7 +237,7 @@ void whenContextRefreshFailedThenWebServerStopFailedCatchStopException() {
236237
.withStackTraceContaining("WebServer has failed to stop");
237238
WebServer webServer = this.context.getWebServer();
238239
then(webServer).should().stop();
239-
then(webServer).should(times(0)).destroy();
240+
then(webServer).should(never()).destroy();
240241
}
241242

242243
@Test

spring-boot-project/spring-boot/src/test/java/org/springframework/boot/web/servlet/server/AbstractServletWebServerFactoryTests.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@
169169
import static org.mockito.BDDMockito.then;
170170
import static org.mockito.Mockito.inOrder;
171171
import static org.mockito.Mockito.mock;
172-
import static org.mockito.Mockito.times;
172+
import static org.mockito.Mockito.never;
173173

174174
/**
175175
* Base for testing classes that extends {@link AbstractServletWebServerFactory}.
@@ -1193,7 +1193,7 @@ protected void servletContextListenerContextDestroyedIsNotCalledWhenContainerIsS
11931193
this.webServer = getFactory().getWebServer((servletContext) -> servletContext.addListener(listener));
11941194
this.webServer.start();
11951195
this.webServer.stop();
1196-
then(listener).should(times(0)).contextDestroyed(any(ServletContextEvent.class));
1196+
then(listener).should(never()).contextDestroyed(any(ServletContextEvent.class));
11971197
}
11981198

11991199
@Test

0 commit comments

Comments
 (0)