Skip to content

Commit 79870dc

Browse files
committed
Upgrade dependencies; prepare for release
* Add `spring-web` test dep for `spring-integration-graphql` module * Fix `MultipartAsRawByteArrayTests` according to the changes in the `ByteArrayHttpMessageConverter` where it uses `ReadNBytes()` even for `0` in `Content-Length` header * Fix Kafka tests to use `RetryListener` interface with `default` methods instead of already deprecated `RetryListenerSupport`
1 parent 1bec420 commit 79870dc

File tree

4 files changed

+31
-26
lines changed

4 files changed

+31
-26
lines changed

build.gradle

+19-17
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ plugins {
1919
id 'io.spring.nohttp' version '0.0.11' apply false
2020
id 'org.ajoberstar.grgit' version '4.1.1'
2121
id 'io.spring.dependency-management' version '1.1.0'
22-
id 'com.jfrog.artifactory' version '4.31.4' apply false
22+
id 'com.jfrog.artifactory' version '4.31.7' apply false
2323
id 'org.jetbrains.dokka' version "$kotlinVersion"
2424
id 'org.asciidoctor.jvm.pdf' version '3.3.2'
2525
id 'org.asciidoctor.jvm.gems' version '3.3.2'
@@ -64,8 +64,8 @@ ext {
6464
findbugsVersion = '3.0.1'
6565
ftpServerVersion = '1.2.0'
6666
graalvmVersion = '22.3.1'
67-
greenmailVersion = '2.0.0-alpha-3'
68-
groovyVersion = '4.0.9'
67+
greenmailVersion = '2.0.0'
68+
groovyVersion = '4.0.10'
6969
hamcrestVersion = '2.2'
7070
hazelcastVersion = '5.2.2'
7171
hibernateVersion = '6.1.7.Final'
@@ -87,31 +87,31 @@ ext {
8787
lettuceVersion = '6.2.3.RELEASE'
8888
log4jVersion = '2.19.0'
8989
mailVersion = '1.0.0'
90-
micrometerTracingVersion = '1.1.0-M1'
91-
micrometerVersion = '1.11.0-M1'
92-
mockitoVersion = '5.1.1'
90+
micrometerTracingVersion = '1.1.0-M2'
91+
micrometerVersion = '1.11.0-M2'
92+
mockitoVersion = '5.2.0'
9393
mongoDriverVersion = '4.9.0'
9494
mysqlVersion = '8.0.32'
9595
pahoMqttClientVersion = '1.2.5'
9696
postgresVersion = '42.5.4'
9797
protobufVersion = '3.21.12'
9898
r2dbch2Version = '1.0.0.RELEASE'
99-
reactorVersion = '2022.0.3'
99+
reactorVersion = '2022.0.5'
100100
resilience4jVersion = '2.0.2'
101-
romeToolsVersion = '2.0.0'
101+
romeToolsVersion = '2.1.0'
102102
rsocketVersion = '1.1.3'
103103
servletApiVersion = '6.0.0'
104104
smackVersion = '4.4.6'
105-
springAmqpVersion = '3.0.2'
106-
springDataVersion = '2023.0.0-M2'
107-
springGraphqlVersion = '1.1.2'
108-
springKafkaVersion = '3.0.3'
109-
springRetryVersion = '2.0.0'
110-
springSecurityVersion = '6.1.0-M1'
111-
springVersion = '6.0.5'
105+
springAmqpVersion = '3.0.3'
106+
springDataVersion = '2023.0.0-M3'
107+
springGraphqlVersion = '1.2.0-M1'
108+
springKafkaVersion = '3.0.5'
109+
springRetryVersion = '2.0.1'
110+
springSecurityVersion = '6.1.0-M2'
111+
springVersion = '6.0.7'
112112
springWsVersion = '4.0.1'
113113
testcontainersVersion = '1.17.6'
114-
tomcatVersion = '11.0.0-M1'
114+
tomcatVersion = '11.0.0-M4'
115115
xmlUnitVersion = '2.9.1'
116116
xstreamVersion = '1.4.20'
117117
ztZipVersion = '1.15'
@@ -364,7 +364,7 @@ configure(javaProjects) { subproject ->
364364

365365
checkstyle {
366366
configDirectory.set(rootProject.file('src/checkstyle'))
367-
toolVersion = project.hasProperty('checkstyleVersion') ? project.checkstyleVersion : '10.8.0'
367+
toolVersion = project.hasProperty('checkstyleVersion') ? project.checkstyleVersion : '10.9.2'
368368
}
369369

370370
jar {
@@ -624,6 +624,8 @@ project('spring-integration-graphql') {
624624
dependencies {
625625
api project(':spring-integration-core')
626626
api "org.springframework.graphql:spring-graphql:$springGraphqlVersion"
627+
628+
testImplementation 'org.springframework:spring-web'
627629
}
628630
}
629631

spring-integration-http/src/test/java/org/springframework/integration/http/inbound/MultipartAsRawByteArrayTests.java

+6-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2015-2022 the original author or authors.
2+
* Copyright 2015-2023 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -32,6 +32,7 @@
3232
import org.springframework.web.context.request.RequestContextHolder;
3333

3434
import static org.assertj.core.api.Assertions.assertThat;
35+
import static org.mockito.ArgumentMatchers.anyInt;
3536
import static org.mockito.Mockito.doReturn;
3637
import static org.mockito.Mockito.mock;
3738
import static org.mockito.Mockito.when;
@@ -57,9 +58,11 @@ public void testMultiPass() throws Exception {
5758
gw.afterPropertiesSet();
5859
gw.start();
5960

61+
String testData = "test data";
62+
6063
HttpServletRequest request = mock(HttpServletRequest.class);
6164
ServletInputStream sis = mock(ServletInputStream.class);
62-
doReturn("test data".getBytes()).when(sis).readAllBytes();
65+
doReturn(testData.getBytes()).when(sis).readNBytes(anyInt());
6366
when(request.getInputStream()).thenReturn(sis);
6467
when(request.getMethod()).thenReturn("POST");
6568
when(request.getHeaderNames()).thenReturn(mock(Enumeration.class));
@@ -70,7 +73,7 @@ public void testMultiPass() throws Exception {
7073
Message<?> received = requestChannel.receive(10000);
7174
assertThat(received).isNotNull();
7275
assertThat(received.getPayload()).isInstanceOf(byte[].class);
73-
assertThat(new String((byte[]) received.getPayload())).isEqualTo("test data");
76+
assertThat(new String((byte[]) received.getPayload())).isEqualTo(testData);
7477
}
7578

7679
}

spring-integration-kafka/src/test/java/org/springframework/integration/kafka/inbound/InboundGatewayTests.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2018-2022 the original author or authors.
2+
* Copyright 2018-2023 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -56,8 +56,8 @@
5656
import org.springframework.messaging.support.ErrorMessage;
5757
import org.springframework.retry.RetryCallback;
5858
import org.springframework.retry.RetryContext;
59+
import org.springframework.retry.RetryListener;
5960
import org.springframework.retry.backoff.NoBackOffPolicy;
60-
import org.springframework.retry.listener.RetryListenerSupport;
6161
import org.springframework.retry.policy.SimpleRetryPolicy;
6262
import org.springframework.retry.support.RetryTemplate;
6363

@@ -392,7 +392,7 @@ void testInboundRetryErrorRecoverWithoutRecoveryCallback(EmbeddedKafkaBroker emb
392392
retryTemplate.setRetryPolicy(retryPolicy);
393393
retryTemplate.setBackOffPolicy(new NoBackOffPolicy());
394394
final CountDownLatch retryCountLatch = new CountDownLatch(retryPolicy.getMaxAttempts());
395-
retryTemplate.registerListener(new RetryListenerSupport() {
395+
retryTemplate.registerListener(new RetryListener() {
396396

397397
@Override
398398
public <T, E extends Throwable> void onError(RetryContext context, RetryCallback<T, E> callback,

spring-integration-kafka/src/test/java/org/springframework/integration/kafka/inbound/MessageDrivenAdapterTests.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2016-2022 the original author or authors.
2+
* Copyright 2016-2023 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -83,7 +83,7 @@
8383
import org.springframework.messaging.support.ErrorMessage;
8484
import org.springframework.retry.RetryCallback;
8585
import org.springframework.retry.RetryContext;
86-
import org.springframework.retry.listener.RetryListenerSupport;
86+
import org.springframework.retry.RetryListener;
8787
import org.springframework.retry.policy.SimpleRetryPolicy;
8888
import org.springframework.retry.support.RetryTemplate;
8989

@@ -310,7 +310,7 @@ protected boolean doSend(Message<?> message, long timeout) {
310310
retryPolicy.setMaxAttempts(2);
311311
retryTemplate.setRetryPolicy(retryPolicy);
312312
final CountDownLatch retryCountLatch = new CountDownLatch(retryPolicy.getMaxAttempts());
313-
retryTemplate.registerListener(new RetryListenerSupport() {
313+
retryTemplate.registerListener(new RetryListener() {
314314

315315
@Override
316316
public <T, E extends Throwable> void onError(RetryContext context, RetryCallback<T, E> callback,

0 commit comments

Comments
 (0)