Skip to content

Commit 72f379a

Browse files
committed
Merge branch '3.2.x' into 3.3.x
Closes gh-42434
2 parents 689a61e + eafe61c commit 72f379a

File tree

23 files changed

+103
-111
lines changed

23 files changed

+103
-111
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ jobs:
2222
- version: 17
2323
toolchain: false
2424
- version: 21
25-
toolchain: true
25+
toolchain: false
2626
- version: 22
27-
toolchain: true
27+
toolchain: false
2828
- version: 23
2929
toolchain: true
3030
exclude:

buildSrc/build.gradle

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,11 @@ repositories {
1010
gradlePluginPortal()
1111
}
1212

13-
sourceCompatibility = 17
14-
targetCompatibility = 17
13+
java {
14+
sourceCompatibility = 17
15+
targetCompatibility = 17
16+
}
17+
1518

1619
if ("${springFrameworkVersion}".contains("-")) {
1720
repositories {
@@ -36,6 +39,7 @@ dependencies {
3639
implementation("com.tngtech.archunit:archunit:1.3.0")
3740
implementation("commons-codec:commons-codec:${commonsCodecVersion}")
3841
implementation("de.undercouch.download:de.undercouch.download.gradle.plugin:5.5.0")
42+
implementation("dev.adamko.dokkatoo:dokkatoo-plugin:2.3.1")
3943
implementation("io.spring.gradle.antora:spring-antora-plugin:0.0.1")
4044
implementation("io.spring.javaformat:spring-javaformat-gradle-plugin:${javaFormatVersion}")
4145
implementation("io.spring.nohttp:nohttp-gradle:0.0.11")

buildSrc/src/main/java/org/springframework/boot/build/KotlinConventions.java

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,15 @@
2121
import java.util.List;
2222

2323
import dev.adamko.dokkatoo.DokkatooExtension;
24-
import dev.adamko.dokkatoo.formats.DokkatooHtmlPlugin;
2524
import org.gradle.api.Project;
2625
import org.gradle.api.tasks.SourceSet;
2726
import org.gradle.api.tasks.SourceSetContainer;
2827
import org.jetbrains.kotlin.gradle.dsl.KotlinJvmOptions;
2928
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile;
3029

3130
/**
32-
* Conventions that are applied in the presence of the {@code org.jetbrains.kotlin.jvm}
33-
* plugin. When the plugin is applied:
31+
* Conventions that are applied in the presence of the
32+
* {@code org.jetbrains.kotlin.jvm} plugin. When the plugin is applied:
3433
*
3534
* <ul>
3635
* <li>{@link KotlinCompile} tasks are configured to:
@@ -67,22 +66,18 @@ private void configure(KotlinCompile compile) {
6766
}
6867

6968
private void configureDokkatoo(Project project) {
70-
project.getPlugins().apply(DokkatooHtmlPlugin.class);
7169
DokkatooExtension dokkatoo = project.getExtensions().getByType(DokkatooExtension.class);
7270
dokkatoo.getDokkatooSourceSets().named(SourceSet.MAIN_SOURCE_SET_NAME).configure((sourceSet) -> {
7371
sourceSet.getSourceRoots().setFrom(project.file("src/main/kotlin"));
74-
sourceSet.getClasspath()
75-
.from(project.getExtensions()
76-
.getByType(SourceSetContainer.class)
77-
.getByName(SourceSet.MAIN_SOURCE_SET_NAME)
78-
.getOutput());
72+
sourceSet.getClasspath().from(project.getExtensions().getByType(SourceSetContainer.class)
73+
.getByName(SourceSet.MAIN_SOURCE_SET_NAME).getOutput());
7974
sourceSet.getExternalDocumentationLinks().create("spring-boot-javadoc", (link) -> {
8075
link.getUrl().set(URI.create("https://docs.spring.io/spring-boot/api/java/"));
8176
link.getPackageListUrl().set(URI.create("https://docs.spring.io/spring-boot/api/java/element-list"));
8277
});
8378
sourceSet.getExternalDocumentationLinks().create("spring-framework-javadoc", (link) -> {
8479
String url = "https://docs.spring.io/spring-framework/docs/%s/javadoc-api/"
85-
.formatted(project.property("springFrameworkVersion"));
80+
.formatted(project.property("springFrameworkVersion"));
8681
link.getUrl().set(URI.create(url));
8782
link.getPackageListUrl().set(URI.create(url + "/element-list"));
8883
});

buildSrc/src/main/java/org/springframework/boot/build/bom/bomr/InteractiveUpgradeResolver.java

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2023 the original author or authors.
2+
* Copyright 2012-2024 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.
@@ -16,6 +16,7 @@
1616

1717
package org.springframework.boot.build.bom.bomr;
1818

19+
import java.util.ArrayList;
1920
import java.util.Collection;
2021
import java.util.HashMap;
2122
import java.util.List;
@@ -58,12 +59,17 @@ private Upgrade resolveUpgrade(LibraryWithVersionOptions libraryWithVersionOptio
5859
if (libraryWithVersionOptions.getVersionOptions().isEmpty()) {
5960
return null;
6061
}
61-
VersionOption current = new VersionOption(libraryWithVersionOptions.getLibrary().getVersion().getVersion());
62-
VersionOption selected = this.userInputHandler.selectOption(
63-
libraryWithVersionOptions.getLibrary().getName() + " "
64-
+ libraryWithVersionOptions.getLibrary().getVersion().getVersion(),
65-
libraryWithVersionOptions.getVersionOptions(), current);
66-
return (selected.equals(current)) ? null
62+
VersionOption defaultOption = new VersionOption(
63+
libraryWithVersionOptions.getLibrary().getVersion().getVersion());
64+
VersionOption selected = this.userInputHandler.askUser((questions) -> {
65+
String question = libraryWithVersionOptions.getLibrary().getName() + " "
66+
+ libraryWithVersionOptions.getLibrary().getVersion().getVersion();
67+
List<VersionOption> options = new ArrayList<>();
68+
options.add(defaultOption);
69+
options.addAll(libraryWithVersionOptions.getVersionOptions());
70+
return questions.selectOption(question, options, defaultOption);
71+
}).get();
72+
return (selected.equals(defaultOption)) ? null
6773
: new Upgrade(libraryWithVersionOptions.getLibrary(), selected.getVersion());
6874
}
6975

buildSrc/src/main/java/org/springframework/boot/build/test/DockerTestPlugin.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ private void configureDockerTesting(Project project) {
7171
.add(project.getConfigurations()
7272
.getByName(dockerTestSourceSet.getRuntimeClasspathConfigurationName())));
7373
});
74+
project.getDependencies()
75+
.add(dockerTestSourceSet.getRuntimeOnlyConfigurationName(), "org.junit.platform:junit-platform-launcher");
7476
}
7577

7678
private SourceSet createSourceSet(Project project) {

buildSrc/src/main/java/org/springframework/boot/build/test/IntegrationTestPlugin.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2023 the original author or authors.
2+
* Copyright 2012-2024 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.
@@ -58,6 +58,8 @@ private void configureIntegrationTesting(Project project) {
5858
eclipse.classpath((classpath) -> classpath.getPlusConfigurations()
5959
.add(project.getConfigurations().getByName(intTestSourceSet.getRuntimeClasspathConfigurationName())));
6060
});
61+
project.getDependencies()
62+
.add(intTestSourceSet.getRuntimeOnlyConfigurationName(), "org.junit.platform:junit-platform-launcher");
6163
}
6264

6365
private SourceSet createSourceSet(Project project) {

gradle/wrapper/gradle-wrapper.jar

121 Bytes
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.4-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

gradlew

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
# See the License for the specific language governing permissions and
1616
# limitations under the License.
1717
#
18+
# SPDX-License-Identifier: Apache-2.0
19+
#
1820

1921
##############################################################################
2022
#
@@ -55,7 +57,7 @@
5557
# Darwin, MinGW, and NonStop.
5658
#
5759
# (3) This script is generated from the Groovy template
58-
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
60+
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
5961
# within the Gradle project.
6062
#
6163
# You can find Gradle at https://github.com/gradle/gradle/.
@@ -84,7 +86,8 @@ done
8486
# shellcheck disable=SC2034
8587
APP_BASE_NAME=${0##*/}
8688
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
87-
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
89+
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s
90+
' "$PWD" ) || exit
8891

8992
# Use the maximum available, or set MAX_FD != -1 to use that value.
9093
MAX_FD=maximum

gradlew.bat

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
@rem See the License for the specific language governing permissions and
1414
@rem limitations under the License.
1515
@rem
16+
@rem SPDX-License-Identifier: Apache-2.0
17+
@rem
1618

1719
@if "%DEBUG%"=="" @echo off
1820
@rem ##########################################################################

0 commit comments

Comments
 (0)