-
Notifications
You must be signed in to change notification settings - Fork 504
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
8263760: Update gradle to version 7.0.1 #498
Conversation
👋 Welcome back kcr! A progress list of the required criteria for merging this PR into |
/issue 8240336 |
@kevinrushforth The primary solved issue for a PR is set through the PR title. Since the current title does not contain an issue reference, it will now be updated. |
@kevinrushforth |
@kevinrushforth |
/issue remove 8263760 |
@kevinrushforth |
@@ -28,7 +44,7 @@ APP_NAME="Gradle" | |||
APP_BASE_NAME=`basename "$0"` | |||
|
|||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. | |||
DEFAULT_JVM_OPTS="" | |||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is automatically generated by Gradle, but the heap memory seems to be too low.
- the same for
gradlew.bat
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with this concern, and will revert this auto-generated change. I don't know why the gradle team felt that a 64Mbyte heap was sufficient.
@kevinrushforth |
List sourceRoots = new ArrayList(); | ||
@Optional @Input String matches; // regex for matching input files | ||
@Input List<String> params = new ArrayList<String>(); | ||
@Input List sourceRoots = new ArrayList(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this be @Internal
?:
updateFiles()
usessourceRoots
and maps that into theallFiles
field, which has already@InputFiles
. If thesourceRoots
is changed in a way that does not affectallFiles
, this task can remainUP_TO_DATE
and save task execution.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps, but I wouldn't want to make this change as part of this bug fix. I'd rather not have to do the analysis of whether there is any case where sourceRoots
can change in a way that wouldn't affect the outputs. If not, then this is only a theoretical concern, and if so, it seems better to err on the side of correctness unless you can prove that all similar cases won't affect the outputs.
@Optional @InputDirectory File headers; | ||
@Optional Closure eachOutputFile; // will be given a File and must return a File | ||
@Optional boolean exe = false; | ||
@Optional @Input Closure eachOutputFile; // will be given a File and must return a File |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this field actually used anywhere?
As this field is not initialized + there is the @Optional
annotation, Gradle will not verify this is fine. Gradle docs is specifying that:
@Input
can be used on Closure if it is a provider ofFile
(which means no param in closure).@Input
can be used for anySerializable
whichClosure
actually is.
It's not obvious if Gradle will correctly handle Closure
taking argument.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll take a look, but I will likely want to do any cleanup of this in a follow-on issue. As you note the eachOutputFile
property is unused...as is the exe
property. They were formerly used by one of the javapackager
tasks, which has since been removed.
Webrevs
|
…cripts" This reverts commit 0b70d09.
On closer inspection, I am reverting my earlier change to
So even though I agree that a 64 Mbyte heap is a bit on the small side, it's more important that running |
I don't think this is a good idea. The only modification of the wrapper scripts would need to be the removal of the heap setting, nothing else. Setting 64MB heap will definitely cause performance issues for JFX builds (because of Garbage collection, not enough memory for caching, ...). + the previous setting was not to restrict the heap in Wrapper scripts. So someone already removed the heap setting as 64MB is the setting back from at least Gradle 4. |
We haven't updated the gradle wrapper since gradle 4.3. I did it this time as a better practice, which came up during the review of PR #411 in this comment. Anyway, I do agree with you that the value is (surprisingly) low, but it's easy to override this by setting the Let's see what the reviewers think. If others think we should change it, I'd certainly be willing to reconsider setting it to a higher value (which seems better than just removing the setting like I did in the earlier, now-reverted commit). |
Isn't that just the settings for running the gradle wrapper - i.e. it is not setting the heap used by the gradle daemon process that will actually run the build script? |
Ah yes, you are right. I just verified this with a test build. So this is definitely not an issue then. Thanks! |
Sorry for confusion. I misunderstand the mechanics. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've ran the build jobs and building and testing both completed successfully on all platforms.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. Verified build and test execution on mac and windows machine.
@kevinrushforth This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 13 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
/integrate |
@kevinrushforth Since your change was applied there have been 13 commits pushed to the
Your commit was automatically rebased without conflicts. Pushed as commit 111bac4. 💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored. |
This PR fixes the gradle deprecation warnings described in JDK-8240336 and updates the JavaFX build to use gradle 7.0.1 as described in JDK-8263760. The minimum version of gradle is set to 6.3.
In addition to keeping gradle up to date, updating to gradle 7 will allow building and testing JavaFX with JDK 16.
I have done a full build and test on all three platforms, comparing the artifacts produced before and after this change.
Notes to Reviewers:
The PR branch has two separate commits, one for each fix, in case reviewers want to look at them separately. As always, they will be squashed into a single commit when integrated. Both bug IDs will be listed in the commit.
The following changes were done for JDK-8240336 to eliminate the use of deprecated features removed in gradle 7:
compile
with eitherimplementation
orcompileClasspath
as neededarchiveName
anddestinationDir
properties in archive tasks witharchiveFileName
anddestinationDirectory
@Input
annotation to custom Groovy task propertiesThe following changes were done for JDK-8263760 to update to gradle 7.0.1:
bash ./gradlew wrapper --gradle-version=7.0.1
build.properties
to7.0.1
gradle/wrapper/gradle-wrapper.properties
Progress
Issues
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jfx pull/498/head:pull/498
$ git checkout pull/498
Update a local copy of the PR:
$ git checkout pull/498
$ git pull https://git.openjdk.java.net/jfx pull/498/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 498
View PR using the GUI difftool:
$ git pr show -t 498
Using diff file
Download this PR as a diff file:
https://git.openjdk.java.net/jfx/pull/498.diff