Skip to content

Commit cf7c13c

Browse files
committed
Minor collection of Gradle 9 fixes
This isn't enough to get Gradle 9 working locally. At the very least, more work will be needed for changes with the shadow plugin. But all of these changes work fine with Gradle 8 as well. In Gradle 9.5.0 DependencyHandler (the class that powers dependencies {}) got a project(String) method, which now shadows the method from Project. The AppEngine plugin pulls in WarPluginConvention, which is removed. GoogleCloudPlatform/appengine-plugins#998 . Disabling the auto-detection behavior for detecting the correct plugin works around the issue. Gradle 9 upgrades to Groovy 4, which removes groovy.util.XmlParser which was replaced by groovy.xml.XmlParser.
1 parent 2c9b067 commit cf7c13c

4 files changed

Lines changed: 5 additions & 5 deletions

File tree

‎all/build.gradle‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ for (subproject in subprojects) {
3838
evaluationDependsOn(':grpc-interop-testing')
3939

4040
dependencies {
41-
api subprojects.minus([project(':grpc-protobuf-lite')])
41+
api subprojects.minus([project.project(':grpc-protobuf-lite')])
4242
implementation libraries.guava.jre // JRE required by transitive protobuf-java-util
4343
}
4444

‎gae-interop-testing/gae-jdk8/build.gradle‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ plugins {
2424
id "war"
2525

2626
id "ru.vyarus.animalsniffer"
27-
id 'com.google.cloud.tools.appengine'
27+
id 'com.google.cloud.tools.appengine-appenginewebxml'
2828
}
2929

3030
description = 'gRPC: gae interop testing (jdk8)'
@@ -102,7 +102,7 @@ String getGaeProject() {
102102
}
103103

104104
String getService(java.nio.file.Path projectPath) {
105-
Node xml = new XmlParser().parse(projectPath.resolve("src/main/webapp/WEB-INF/appengine-web.xml").toFile())
105+
Node xml = new groovy.xml.XmlParser().parse(projectPath.resolve("src/main/webapp/WEB-INF/appengine-web.xml").toFile())
106106
if (xml.service.isEmpty()) {
107107
return "default"
108108
} else {

‎netty/shaded/build.gradle‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ dependencies {
6262
project(':grpc-testing-proto'),
6363
project(':grpc-testing'),
6464
libraries.truth
65-
shadow project(':grpc-netty').configurations.runtimeClasspath.allDependencies.matching {
65+
shadow project.project(':grpc-netty').configurations.runtimeClasspath.allDependencies.matching {
6666
it.group != 'io.netty'
6767
}
6868
signature (libraries.signature.java) {

‎settings.gradle‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ pluginManagement {
2020
// https://github.com/kt3k/coveralls-gradle-plugin/tags
2121
id "com.github.kt3k.coveralls" version "2.12.2"
2222
// https://github.com/GoogleCloudPlatform/appengine-plugins/releases
23-
id "com.google.cloud.tools.appengine" version "2.8.7"
23+
id "com.google.cloud.tools.appengine-appenginewebxml" version "2.8.7"
2424
// https://github.com/GoogleContainerTools/jib/blob/master/jib-gradle-plugin/CHANGELOG.md
2525
id "com.google.cloud.tools.jib" version "3.5.4"
2626
// https://github.com/google/osdetector-gradle-plugin/tags

0 commit comments

Comments
 (0)