Open donat opened 1 year ago
Thanks for the note! Do you have an estimate on when Gradle 8.0 will release?
There's no clear eta for the release at this point, but the main branch is already set to 8.0. It will be the next release after the upcoming 7.6.
Thanks for the context @donat. Also linking the official docs here for future reference: https://docs.gradle.org/current/dsl/org.gradle.api.plugins.WarPluginConvention.html.
For the record: this removal was postponed to 9.0, and the Conventions are now nagging since Gradle 8.2.
I did a little bit of investigation: To make this plugin compatible, it's necessary to get access to the webAppDir
, but without the convention. In Gradle 7.1 there's a new property introduced War.webAppDirectory
, but this plugin's minimum is Gradle 4.0. Without the convention there's no way to access the directory, because it only propagates into AbstractCopyTask.from
, which is a write-only method. This means that after convention removal reflection will be necessary to support Gradle 7.0 and earlier, or hopefully https://github.com/gradle/gradle/issues/25132 will help, but for that the build needs to be upgraded which is a lot of work (first step is https://github.com/GoogleCloudPlatform/app-gradle-plugin/pull/398).
I ran into this again, while upgrading an old project.
> Configure project :AppEngine
while executing line apply plugin: 'com.google.cloud.tools.appengine'
.
I captured the nagging stack traces on Gradle 8.2.1 for reference.
Luckily there's a trivial workaround: avoid using the generic com.google.cloud.tools.appengine
plugin as documented in the user guide, migrate from option 3. to option 1. or 2. depending on what type of project you have.
@donat what's the plan, is this more likely going ahead in 9.0?
The type will be removed in Gradle 8.0.
https://github.com/GoogleCloudPlatform/app-gradle-plugin/blob/f50be8dcdde14ec6ef94947f1e21f5ea855be792/src/main/java/com/google/cloud/tools/gradle/appengine/AppEnginePlugin.java#L28