RATIS-2362. Use maven.compiler.release for target Java version #74
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.
What changes were proposed in this pull request?
maven.compiler.sourcewithmaven.compiler.releasemaven.compiler.target, but set it to the same asmaven.compiler.release. This is required because Apache parent POM v35 uses.targetas the source of truth.java.min.versionandmaven.min.versionproperties, andmaven-enforcer-pluginexecutions that reference these. Enforcement is inherited from Parent POM (properties, execution).javac.source.extra-enforcer-rulesversion.https://issues.apache.org/jira/browse/RATIS-2362
How was this patch tested?
Tested with various Java and Maven versions. For successful builds also verified generated Java
.classfile version.Exactly minimum required versions:
Newer versions:
Targeting Java 17:
Maven too old (fails due to several plugins, even before enforcer):
Maven older than custom requirement:
Java older than target:
CI:
https://github.com/adoroszlai/ratis-thirdparty/actions/runs/19389063242