-
Notifications
You must be signed in to change notification settings - Fork 40.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
spring-boot-maven-plugin doesn't work with Java 22 #39927
Comments
Can reproduce this. Here's the stacktrace:
|
Same with 3.3.0-SNAPSHOT. |
The maven plugin uses spring-core:6.0.10:
but otherwise a current version of the framework dependencies:
Is that because of the dependencies on |
Oh dear. Those mixed versions are bad. We had to downgrade to Framework 6.0.x in the build plugin-related projects to work around this Gradle bug that's been fixed in Gradle 7.6.4. As a first step, I think we should try to configure the Maven plugin to consistently use 6.1.x. As a second step, and probably in a separate issue, we'll have to figure out what to do about Gradle. I'm not sure how we can both support Java 22 and Gradle versions < 7.6.4. We could raise the minimum supported version of Gradle for Boot 3.3 but that'd still leave us with a problem in Boot 3.2.x. |
Gradle does not yet support Java 22. 8.7, currently in its RC phase will support using a Java 22 toolchain but won't support running Gradle itself on Java 22. That buys us some time on the Gradle side of things. |
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [nu.ndw.nls.geometry:nls-geometry](https://spring.io/projects/spring-boot) ([source](https://github.com/spring-projects/spring-boot)) | compile | patch | `3.2.0` -> `3.2.4` | | [commons-io:commons-io](https://commons.apache.org/proper/commons-io/) ([source](https://gitbox.apache.org/repos/asf?p=commons-io.git)) | compile | minor | `2.17.0` -> `2.18.0` | | [org.springframework.boot:spring-boot-starter-parent](https://spring.io/projects/spring-boot) ([source](https://github.com/spring-projects/spring-boot)) | parent | minor | `3.3.5` -> `3.4.0` | --- ### Release Notes <details> <summary>spring-projects/spring-boot (nu.ndw.nls.geometry:nls-geometry)</summary> ### [`v3.2.4`](https://github.com/spring-projects/spring-boot/releases/tag/v3.2.4) [Compare Source](spring-projects/spring-boot@v3.2.3...v3.2.4) #### ⭐ New Features - Add TWENTY_TWO to JavaVersion enum [#​39825](spring-projects/spring-boot#39825) #### 🐞 Bug Fixes - Thread name prefix is not always set when using virtual threads [#​39958](spring-projects/spring-boot#39958) - spring-boot-maven-plugin doesn't work with Java 22 [#​39927](spring-projects/spring-boot#39927) - Resolving a BuildpackReference created from a URL-like String can fail on Windows [#​39793](spring-projects/spring-boot#39793) - SpringProfile arbiter fails without a Spring's environment [#​39786](spring-projects/spring-boot#39786) - bootStartScripts tasks should be an instance of org.gradle.api.tasks.application.CreateStartScripts rather than its superclass org.gradle.jvm.application.tasks.CreateStartScripts [#​39764](spring-projects/spring-boot#39764) - When using Logback, log messages appear in a single line when application name contains brackets [#​39564](spring-projects/spring-boot#39564) #### 📔 Documentation - Document support for Java 22 [#​40046](spring-projects/spring-boot#40046) - Fix web session javadoc typo [#​39821](spring-projects/spring-boot#39821) - Fix typo in Custom HTTP Exchange Recording section [#​39784](spring-projects/spring-boot#39784) - Make description of virtual threads and JVM exit easier to understand by removing "no-non" double-negative [#​39732](spring-projects/spring-boot#39732) #### 🔨 Dependency Upgrades - Upgrade to Angus Mail 2.0.3 [#​39973](spring-projects/spring-boot#39973) - Upgrade to Glassfish JAXB 4.0.5 [#​39975](spring-projects/spring-boot#39975) - Upgrade to Graph...
Steps to reproduce:
<java.version>21</java.version>
to<java.version>22</java.version>
mvn clean verify
Results with:
This is because spring-boot-maven-plugin:3.2.3 uses old ASM version 9.5. Easily to see using
mvn dependency:resolve-plugins
:The text was updated successfully, but these errors were encountered: