Skip to content

Handle Java source versions other than 8 for compile-jsp#1813

Merged
cherylking merged 5 commits intoOpenLiberty:mainfrom
cherylking:updateCompileJsp
May 6, 2024
Merged

Handle Java source versions other than 8 for compile-jsp#1813
cherylking merged 5 commits intoOpenLiberty:mainfrom
cherylking:updateCompileJsp

Conversation

@cherylking
Copy link
Copy Markdown
Member

@cherylking cherylking commented May 3, 2024

Fixes #1812

This PR does the minimum necessary to fix the issue:

  • Checks for and uses the release parameter for setSource if it is specified in the project maven-compiler-plugin config
  • If that is not found, checks for and uses the source parameter for setSource if it is specified in the project maven-compiler-plugin config
  • If neither of those are found, check for and use maven.compiler.release Maven property or maven.compiler.source Maven property if specified.
  • If neither are found, the Ant task defaults to using the System property java.specification.version
  • The ant task will also use javaSourceLevel if the version of Liberty is 24.0.0.1 or later and the value used for source is Java 8 or later. Otherwise, it will still use jdkSourceLevel for older versions of Liberty.

@cherylking
Copy link
Copy Markdown
Member Author

Doc for reference - versions older than 24.0.0.1 do not document a javaSourceLevel attribute.

@cherylking cherylking requested a review from mattbsox May 4, 2024 19:55
@cherylking cherylking merged commit 3aa3884 into OpenLiberty:main May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Goal 'compile-jsp' uses wrong source/target

3 participants