Upgrades to cf-java-client#1201
Merged
pivotal-david-osullivan merged 3 commits intocloudfoundry:mainfrom Dec 21, 2023
Merged
Conversation
It's been 7 months since the 5.10.0.RELEASE. The current release documentation states that that release is compatible with Spring Boot release versions up to 2.6.x. Meanwhile, Spring Boot 3.1.x is the current release, with Spring Boot 3.2.x nearing GA. There's not much that needed to change to prepare a version of the cf-java-client to be compatible with Spring Boot 3.1.x, but it does require setting target to Java 17. That required a change to the maven-compiler-plugin compileArgs configuration to facilitate source code generation and data-binding when using Immutables. I also took the test dependencies forward, so that in the future, the tests could be refactored to leverage JUnit 5 APIs. The rest of the changes are pretty straight-forward, just upgrades to dependencies and plugins to the latest available as of the date of this pull request. Default build with Maven 3.9.4 targets Java 8 and upgrades Spring Boot to 2.7.16. Maven profiles get activated based on the installed version of the JDK detected. These profiles update the dependencies and plugins to support compilation and testing on Java 17 and 21 with Spring Boot 3.1.4 dependency management. A Github Action workflow was added to provide signal on "good builds". Currently, tests fail when targeting either Java 17 or 21. See this open issue for more details: immutables/immutables#1339. > This PR was based upon earlier work in cloudfoundry#1198.
* support for building cf-java-client with Java 8, 11, 17, and 21
Contributor
|
@pivotal-david-osullivan I think this PR puts us in a good spot: removed unused imports, deps upgrades, and I checked it builds on Java 8 We can address JDK 17 and 21 Immutable issues in a later PR LGTM, please review! (I don't have approver rights on this project) |
* active when compile target is JDK 8 * update .gitignore to exclude all sub-directories underneath .idea and exclude .history directory * replace javax.annotation with jakarta.annotation
pivotal-david-osullivan
approved these changes
Dec 21, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It's been 7 months since the 5.10.0.RELEASE. The current release documentation states that that release is compatible with Spring Boot release versions up to 2.6.x. Meanwhile, Spring Boot 3.1.x is the current release, with Spring Boot 3.2.x nearing GA.
There's not much that needed to change to prepare a version of the cf-java-client to be compatible with Spring Boot 3.1.x, but it does require setting target to Java 17. That required a change to the maven-compiler-plugin compileArgs configuration to facilitate source code generation and data-binding when using Immutables. I also took the test dependencies forward, so that in the future, the tests could be refactored to leverage JUnit 5 APIs. The rest of the changes are pretty straight-forward, just upgrades to dependencies and plugins to the latest available as of the date of this pull request.
Default build with Maven 3.9.4 targets Java 8 and upgrades Spring Boot to 2.7.16.
Maven profiles get activated based on the installed version of the JDK detected. These profiles update the dependencies and plugins to support compilation and testing on Java 17 and 21 with Spring Boot 3.1.4 dependency management.
A Github Action workflow was added to provide signal on "good builds".
Currently, tests fail when targeting either Java 17 or 21. See this open issue for more details: immutables/immutables#1339.
Also did a fair amount of cleanup across Maven child modules where we had unused imports.