From 18e2626bae5316ce547aed53431dd5b992eda873 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Fri, 29 Aug 2025 15:06:34 -0400 Subject: [PATCH 01/16] chore: Update renovate config to support dependencies.txt customMamager --- dependencies.txt | 70 +++++++++++----------- renovate.json | 150 ++--------------------------------------------- 2 files changed, 42 insertions(+), 178 deletions(-) diff --git a/dependencies.txt b/dependencies.txt index d2f6324ca1..b9d9be0a6a 100644 --- a/dependencies.txt +++ b/dependencies.txt @@ -1,48 +1,50 @@ # This file contains a list of dependencies and their versions to be tested for compatibility. -# The format is key=value, where the key is the dependency name and the value is the version. +# The format is `{GroupID}:{ArtifactID}:{Version}:{MavenPropertyName}`. The GAV coordinates +# (specifically the GroupID and ArtifactID are parsed by renovate to find the artifact from Maven +# Central. Version stores the currently known upper bound. MavenPropertyName corresponds to the +# Maven property value in the pom.xml (it is not a 1:1 mapping to the GAV). # "1P" refers to First-Party dependencies (owned by Google). # "3P" refers to Third-Party dependencies. # Pom-Parent Dependencies # These dependencies are declared: https://github.com/googleapis/sdk-platform-java/blob/main/gapic-generator-java-pom-parent/pom.xml -javax.annotation-api=1.3.2 -grpc=1.75.0 -google.auth=1.39.1 -google.http-client=2.0.1 -gson=2.13.2 -guava=33.5.0-jre -protobuf=4.32.1 -# Note: This opentelemetry version refers to the opentelemetry-bom -opentelemetry=1.54.1 -errorprone=2.42.0 -j2objc-annotations=3.1 -threetenbp=1.7.2 -slf4j=2.0.17 +javax.annotation:javax.annotation-api:1.3.2:javax.annotation-api +io.grpc:grpc-bom:1.74.0:grpc +com.google.auth:google.google-auth-library-bom:1.37.1:google.auth +com.google.http-client:google-http-client:1.47.1:google.http-client +com.google.code.gson:gson:2.13.1:gson +com.google.guava:guava:33.4.8-jre:guava +com.google.protobuf:protobuf-java:4.31.1:protobuf +io.opentelemetry:opentelemetry-bom:1.52.0:opentelemetry +com.google.errorprone:error_prone_annotations:2.41.0:errorprone +com.google.j2objc:j2objc-annotations:3.1:j2objc-annotations +org.threeten:threetenbp:1.7.2:threetenbp +org.slf4j:slf4j-api:2.0.17:slf4j # 1P Shared-Deps # These dependencies are declared: https://github.com/googleapis/sdk-platform-java/blob/main/java-shared-dependencies/first-party-dependencies/pom.xml -grpc-gcp=1.7.0 -google.oauth-client=1.39.0 -google.api-client=2.8.1 +com.google.cloud:grpc-gcp:1.6.1:grpc-gcp +com.google.oauth-client:google-oauth-client:1.39.0:google.oauth-client +com.google.api-client:google-api-client:2.8.1:google.api-client # 3P Shared-Deps # These dependencies are declared: https://github.com/googleapis/sdk-platform-java/blob/main/java-shared-dependencies/third-party-dependencies/pom.xml -threeten-extra=1.8.0 -opencensus=0.31.1 -findbugs=3.0.2 -jackson=2.20.0 -codec=1.19.0 -httpcomponents.httpcore=4.4.16 -httpcomponents.httpclient=4.5.14 -apache-httpclient-5=5.5.1 -apache-httpcore-5=5.3.6 -perfmark-api=0.27.0 +org.threeten:threeten-extra:1.8.0:threeten-extra +io.opencensus:opencensus-api:0.31.0:opencensus +com.google.code.findbugs:jsr305:3.0.2:findbugs +com.fasterxml.jackson:jackson-bom:2.19.2:jackson +commons-codec:commons-codec:1.19.0:codec +org.apache.httpcomponents:httpclient:4.5.14:httpcomponents.httpclient +org.apache.httpcomponents:httpcore:4.4.16:httpcomponents.httpcore +org.apache.httpcomponents.client5:httpclient5:5.5:apache-httpclient-5 +org.apache.httpcomponents.core5:httpcore5:5.3.4:apache-httpcore-5 +io.perfmark:perfmark-api:0.27.0:perfmark-api # Note: This is the google opentelemetry exporter and not the general opentelemetry project -google.cloud.opentelemetry=0.36.0 -flogger=0.9 -arrow=18.3.0 -dev.cel=0.11.0 -com.google.crypto.tink=1.18.0 +com.google.cloud.opentelemetry:exporter-metrics:0.36.0:google.cloud.opentelemetry +com.google.flogger:flogger:0.9:flogger +org.apache.arrow:arrow-memory-core:18.3.0:arrow +dev.cel:cel:0.10.1:dev.cel +com.google.crypto.tink:tink:1.18.0:com.google.crypto.tink # The follow opentelemetry dependencies have a different version from the opentelemetry-bom -opentelemetry-semconv=1.37.0 -io.opentelemetry.contrib.opentelemetry-gcp-resources=1.50.0-alpha +io.opentelemetry.semconv:opentelemetry-semconv:1.34.0:opentelemetry-semconv +io.opentelemetry.contrib:opentelemetry-gcp-resources:1.48.0-alpha:io.opentelemetry.contrib.opentelemetry-gcp-resources \ No newline at end of file diff --git a/renovate.json b/renovate.json index ee4e763c36..ea93b0b13a 100644 --- a/renovate.json +++ b/renovate.json @@ -10,6 +10,12 @@ "^library_generation/requirements\\.txt$" ], "customManagers": [ + { + "customType": "regex", + "managerFilePatterns": ["/dependencies\\.txt/"], + "matchStrings": ["(?.*)=(?.*)\\n"], + "datasourceTemplate": "maven" + }, { "customType": "regex", "fileMatch": [ @@ -66,150 +72,6 @@ ], "depNameTemplate": "com.google.cloud:google-cloud-shared-config", "datasourceTemplate": "maven" - }, - { - "customType": "regex", - "fileMatch": [ - "^.cloudbuild/library_generation/library_generation.*\\.Dockerfile$" - ], - "matchStrings": [ - "OWLBOT_CLI_COMMITTISH=(?.*?)\\n" - ], - "currentValueTemplate": "main", - "depNameTemplate": "repo-automation-bots", - "packageNameTemplate": "https://github.com/googleapis/repo-automation-bots", - "datasourceTemplate": "git-refs" - } - ], - "packageRules": [ - { - "matchPackageNames": [ - "com.google.cloud:google-cloud-shared-config" - ], - "registryUrls": [ - "https://repo.maven.apache.org/maven2/", - "https://repo1.maven.org/maven2" - ] - }, - { - "matchUpdateTypes": [ - "major" - ], - "enabled": false, - "matchPackageNames": [ - "*" - ] - }, - { - "enabled": false, - "matchPackageNames": [ - "/^com.google.protobuf:/" - ] - }, - { - "versioning": "docker", - "matchPackageNames": [ - "/^com.google.guava:/" - ], - "enabled": false - }, - { - "semanticCommitType": "deps", - "semanticCommitScope": null, - "matchPackageNames": [ - "*" - ] - }, - { - "semanticCommitType": "build", - "semanticCommitScope": "deps", - "enabled": true, - "matchPackageNames": [ - "/^org.apache.maven/", - "/^org.jacoco:/", - "/^org.codehaus.mojo:/", - "/^org.sonatype.plugins:/", - "/^com.google.cloud:google-cloud-shared-config/" - ] - }, - { - "semanticCommitType": "chore", - "semanticCommitScope": "deps", - "matchPackageNames": [ - "/^{{metadata['repo']['distribution_name']}}/", - "/^com.google.cloud:libraries-bom/", - "/^com.google.cloud.samples:shared-configuration/" - ] - }, - { - "semanticCommitType": "test", - "semanticCommitScope": "deps", - "matchPackageNames": [ - "/^junit:junit/", - "/^com.google.truth:truth/", - "/^org.mockito:mockito-core/", - "/^org.objenesis:objenesis/", - "/^com.google.cloud:google-cloud-conformance-tests/" - ] - }, - { - "ignoreUnstable": false, - "matchPackageNames": [ - "/^com.google.cloud:google-cloud-/" - ] - }, - { - "groupName": "jackson dependencies", - "matchPackageNames": [ - "/^com.fasterxml.jackson.core/" - ] - }, - { - "groupName": "gRPC dependencies", - "matchPackageNames": [ - "/^io.grpc/" - ], - "enabled": false - }, - { - "groupName": "Google Auth Library dependencies", - "matchPackageNames": [ - "/^com.google.auth/" - ] - }, - { - "groupName": "Google API dependencies", - "matchPackageNames": [ - "/com.google.api.grpc:grpc-google-common-protos/", - "/com.google.api.grpc:grpc-google-iam-v1/", - "/com.google.api.grpc:proto-google-common-protos/", - "/com.google.api.grpc:proto-google-iam-v1/", - "/com.google.api:api-common/" - ] - }, - { - "groupName": "Google HTTP Client dependencies", - "matchPackageNames": [ - "/^com.google.http-client/" - ] - }, - { - "groupName": "OpenCensus dependencies", - "matchPackageNames": [ - "/^io.opencensus/" - ] - }, - { - "groupName": "Netty dependencies", - "matchPackageNames": [ - "/^io.netty/" - ] - }, - { - "groupName": "Error Prone dependencies", - "matchPackageNames": [ - "/^com.google.errorprone/" - ] } ] } From b6d840ab41a81c083076e68c8579ca7dcddbfc04 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Fri, 29 Aug 2025 15:17:38 -0400 Subject: [PATCH 02/16] chore: Update the properties value to match dependencies.txt --- ...ownstream-protobuf-source-compatibility.sh | 4 +- api-common-java/pom.xml | 2 +- gapic-generator-java-bom/pom.xml | 10 +- gapic-generator-java-pom-parent/pom.xml | 416 +++++++++--------- gapic-generator-java/pom.xml | 4 +- gax-java/pom.xml | 12 +- java-common-protos/pom.xml | 4 +- java-core/pom.xml | 2 +- java-iam/pom.xml | 4 +- .../first-party-dependencies/pom.xml | 8 +- .../third-party-dependencies/pom.xml | 80 ++-- 11 files changed, 273 insertions(+), 273 deletions(-) diff --git a/.kokoro/nightly/downstream-protobuf-source-compatibility.sh b/.kokoro/nightly/downstream-protobuf-source-compatibility.sh index aaa65b8208..62b7795ba1 100755 --- a/.kokoro/nightly/downstream-protobuf-source-compatibility.sh +++ b/.kokoro/nightly/downstream-protobuf-source-compatibility.sh @@ -48,7 +48,7 @@ for repo in ${REPOS_UNDER_TEST//,/ }; do # Split on comma -Denforcer.skip \ -Dmaven.javadoc.skip \ -Denforcer.skip \ - -Dprotobuf.version=${PROTOBUF_RUNTIME_VERSION} \ + -Dprotobuf-java.version=${PROTOBUF_RUNTIME_VERSION} \ -pl "${google_cloud_java_handwritten_maven_args}" -am \ "${surefire_opt}" \ -T 1C @@ -58,7 +58,7 @@ for repo in ${REPOS_UNDER_TEST//,/ }; do # Split on comma -Denforcer.skip \ -Dmaven.javadoc.skip \ -Denforcer.skip \ - -Dprotobuf.version=${PROTOBUF_RUNTIME_VERSION} \ + -Dprotobuf-java.version=${PROTOBUF_RUNTIME_VERSION} \ "${surefire_opt}" \ -T 1C fi diff --git a/api-common-java/pom.xml b/api-common-java/pom.xml index 997184e27e..6236d450ca 100644 --- a/api-common-java/pom.xml +++ b/api-common-java/pom.xml @@ -63,7 +63,7 @@ com.google.errorprone error_prone_annotations - ${errorprone.version} + ${error_prone_annotations.version} compile diff --git a/gapic-generator-java-bom/pom.xml b/gapic-generator-java-bom/pom.xml index 9eaa0b3a80..dfef2cef15 100644 --- a/gapic-generator-java-bom/pom.xml +++ b/gapic-generator-java-bom/pom.xml @@ -25,14 +25,14 @@ com.google.auth google-auth-library-bom - ${google.auth.version} + ${google-auth-library-bom.version} pom import com.google.auth google-auth-library-oauth2-http - ${google.auth.version} + ${google-auth-library-bom.version} test-jar testlib test @@ -40,7 +40,7 @@ com.google.http-client google-http-client-bom - ${google.http-client.version} + ${google-http-client.version} pom import @@ -59,14 +59,14 @@ com.google.protobuf protobuf-bom - ${protobuf.version} + ${protobuf-java.version} pom import io.grpc grpc-bom - ${grpc.version} + ${grpc-bom.version} pom import diff --git a/gapic-generator-java-pom-parent/pom.xml b/gapic-generator-java-pom-parent/pom.xml index 5d06c46f47..d04eeeb91e 100644 --- a/gapic-generator-java-pom-parent/pom.xml +++ b/gapic-generator-java-pom-parent/pom.xml @@ -1,217 +1,217 @@ - 4.0.0 - com.google.api - gapic-generator-java-pom-parent - 2.62.4-SNAPSHOT - pom - GAPIC Generator Java POM Parent - https://github.com/googleapis/sdk-platform-java - - The top-level parent for all modules in the repository. - - - com.google.cloud - google-cloud-shared-config - 1.16.1 - - + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" child.project.url.inherit.append.path="false"> + 4.0.0 + com.google.api + gapic-generator-java-pom-parent + 2.62.4-SNAPSHOT + pom + GAPIC Generator Java POM Parent + https://github.com/googleapis/sdk-platform-java + + The top-level parent for all modules in the repository. + + + com.google.cloud + google-cloud-shared-config + 1.16.1 + + - - false - java.header + + false + java.header - - 1.3.2 - 1.71.0 - 1.39.1 - 1.47.1 - 2.12.1 - 33.4.0-jre - 3.25.8 - 1.47.0 - 8 - 2.38.0 - 3.0.0 - 1.7.0 - 5.11.4 - 4.11.0 - 2.0.16 - + + 1.3.2 + 1.71.0 + 1.39.1 + 1.47.1 + 2.12.1 + 33.4.0-jre + 3.25.8 + 1.47.0 + 8 + 2.38.0 + 3.0.0 + 1.7.0 + 5.11.4 + 4.11.0 + 2.0.16 + - - - suztomo - Tomo Suzuki - suztomo@google.com - Google - - Developer - - - - - Google LLC - - - scm:git:git@github.com:googleapis/sdk-platform-java.git - scm:git:git@github.com:googleapis/sdk-platform-java.git - https://github.com/googleapis/sdk-platform-java - HEAD - - - https://github.com/googleapis/sdk-platform-java/issues - GitHub Issues - + + + suztomo + Tomo Suzuki + suztomo@google.com + Google + + Developer + + + + + Google LLC + + + scm:git:git@github.com:googleapis/sdk-platform-java.git + scm:git:git@github.com:googleapis/sdk-platform-java.git + https://github.com/googleapis/sdk-platform-java + HEAD + + + https://github.com/googleapis/sdk-platform-java/issues + GitHub Issues + - - - Apache-2.0 - https://www.apache.org/licenses/LICENSE-2.0.txt - - + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0.txt + + - - - - checkstyle-tests - - [11,) - - - - - org.apache.maven.plugins - maven-checkstyle-plugin - - - checkstyle - validate - - check - - - ${checkstyle.header.file} - - - - - - - + + + + checkstyle-tests + + [11,) + + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + + checkstyle + validate + + check + + + ${checkstyle.header.file} + + + + + + + - - test-coverage - - - enableShowcaseTestCoverage - - - - - - - org.apache.maven.plugins - maven-surefire-plugin - 3.5.2 - - - - **/*SmokeTest.java - **/IT*.java - - sponge_log - ${surefire.jacoco.args} - ${skipUnitTests} - - + + test-coverage + + + enableShowcaseTestCoverage + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + 3.5.2 + + + + **/*SmokeTest.java + **/IT*.java + + sponge_log + ${surefire.jacoco.args} + ${skipUnitTests} + + - - org.apache.maven.plugins - maven-failsafe-plugin - 3.5.2 - - - - integration-test - verify - - - - - 3600 - sponge_log - - **/IT*.java - **/*SmokeTest.java - - ${failsafe.jacoco.args} - - - - - - - org.jacoco - jacoco-maven-plugin - 0.8.13 - - - unit-test-execution - - prepare-agent - - - surefire.jacoco.args - - - - integration-test-execution - pre-integration-test - - prepare-agent - - - failsafe.jacoco.args - - - - - - - - - envVarTest - - - - org.apache.maven.plugins - maven-surefire-plugin - - - - **/*.java - - - - - - - - - - google-maven-central-copy - Google Maven Central copy - https://maven-central.storage-download.googleapis.com/maven2 - - - maven-central - Maven Central - https://repo1.maven.org/maven2 - - - + + org.apache.maven.plugins + maven-failsafe-plugin + 3.5.2 + + + + integration-test + verify + + + + + 3600 + sponge_log + + **/IT*.java + **/*SmokeTest.java + + ${failsafe.jacoco.args} + + + + + + + org.jacoco + jacoco-maven-plugin + 0.8.13 + + + unit-test-execution + + prepare-agent + + + surefire.jacoco.args + + + + integration-test-execution + pre-integration-test + + prepare-agent + + + failsafe.jacoco.args + + + + + + + + + envVarTest + + + + org.apache.maven.plugins + maven-surefire-plugin + + + + **/*.java + + + + + + + + + + google-maven-central-copy + Google Maven Central copy + https://maven-central.storage-download.googleapis.com/maven2 + + + maven-central + Maven Central + https://repo1.maven.org/maven2 + + + \ No newline at end of file diff --git a/gapic-generator-java/pom.xml b/gapic-generator-java/pom.xml index 84d579d85b..8d742fa2bd 100644 --- a/gapic-generator-java/pom.xml +++ b/gapic-generator-java/pom.xml @@ -247,7 +247,7 @@ 0.6.1 - com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier} + com.google.protobuf:protoc:${protobuf-java.version}:exe:${os.detected.classifier} @@ -450,7 +450,7 @@ com.google.errorprone error_prone_annotations - ${errorprone.version} + ${error_prone_annotations.version} 3.49.0 0.27.0 3.0.0 - 0.33.0 + 0.33.0 2.1.0-alpha 1.29.0-alpha 0.8 - 17.0.0 - 0.6.0 - 1.16.0 - 1.45.0-alpha + 17.0.0 + 0.6.0 + 1.16.0 + 1.45.0-alpha @@ -53,37 +53,37 @@ org.apache.arrow arrow-memory-core - ${arrow.version} + ${arrow-memory-core.version} org.apache.arrow arrow-memory-netty - ${arrow.version} + ${arrow-memory-core.version} org.apache.arrow arrow-vector - ${arrow.version} + ${arrow-memory-core.version} org.apache.httpcomponents httpcore - ${httpcomponents.httpcore.version} + ${httpcore.version} org.apache.httpcomponents httpclient - ${httpcomponents.httpclient.version} + ${httpclient.version} org.apache.httpcomponents.core5 httpcore5 - ${apache-httpcore-5.version} + ${httpcore5.version} org.apache.httpcomponents.client5 httpclient5 - ${apache-httpclient-5.version} + ${httpclient5-5.version} org.threeten @@ -109,12 +109,12 @@ com.google.code.findbugs jsr305 - ${findbugs.version} + ${jsr305.version} com.google.errorprone error_prone_annotations - ${errorprone.version} + ${error_prone_annotations.version} @@ -131,19 +131,19 @@ com.fasterxml.jackson jackson-bom - ${jackson.version} + ${jackson-bom.version} pom import commons-codec commons-codec - ${codec.version} + ${commons-codec.version} io.opentelemetry opentelemetry-bom - ${opentelemetry.version} + ${opentelemetry-bom.version} pom import @@ -167,59 +167,59 @@ com.google.cloud.opentelemetry exporter-metrics - ${google.cloud.opentelemetry.version} + ${exporter-metrics.version} com.google.cloud.opentelemetry shared-resourcemapping - ${google.cloud.opentelemetry.version} + ${exporter-metrics.version} io.opentelemetry.contrib opentelemetry-gcp-resources - ${io.opentelemetry.contrib.opentelemetry-gcp-resources.version} + ${opentelemetry-gcp-resources.version} io.opencensus opencensus-api - ${opencensus.version} + ${opencensus-api.version} io.opencensus opencensus-contrib-grpc-util - ${opencensus.version} + ${opencensus-api.version} io.opencensus opencensus-contrib-http-util - ${opencensus.version} + ${opencensus-api.version} io.opencensus opencensus-contrib-zpages - ${opencensus.version} + ${opencensus-api.version} io.opencensus opencensus-exporter-stats-stackdriver - ${opencensus.version} + ${opencensus-api.version} io.opencensus opencensus-exporter-trace-stackdriver - ${opencensus.version} + ${opencensus-api.version} io.opencensus opencensus-impl - ${opencensus.version} + ${opencensus-api.version} io.opencensus opencensus-impl-core - ${opencensus.version} + ${opencensus-api.version} org.checkerframework @@ -239,7 +239,7 @@ com.google.cloud.opentelemetry detector-resources-support - ${google.cloud.opentelemetry.version} + ${exporter-metrics.version} org.junit @@ -251,12 +251,12 @@ dev.cel cel - ${dev.cel.version} + ${cel.version} com.google.crypto.tink tink - ${com.google.crypto.tink.version} + ${tink.version} From 56cb44ae7b3bd6baf08b63a312e6b3e00b950c05 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Fri, 29 Aug 2025 15:28:52 -0400 Subject: [PATCH 03/16] chore: Update test dependency script --- .github/scripts/test_dependency_compatibility.sh | 7 +++++-- java-shared-dependencies/third-party-dependencies/pom.xml | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index f2a5ae638e..159fb3d078 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -19,7 +19,7 @@ # # The default upper-bound dependencies file is `dependencies.txt` located in the root # of sdk-platform-java. The upper-bound dependencies file will be in the format of: -# ${dependency.name}=${dependency.version} +# {groupId}:{artifactId}={version} or {artifactId}={version} set -ex @@ -36,7 +36,10 @@ function add_dependency_to_maven_command() { echo "Malformed dependency string: ${dep_pair}. Expected format: dependency=version" exit 1 fi - local dependency=$(echo "${dep_pair}" | cut -d'=' -f1 | tr -d '[:space:]') + local full_dependency=$(echo "${dep_pair}" | cut -d'=' -f1 | tr -d '[:space:]') + # The dependency can be in the format of {groupId}:{artifactId} or {artifactId} + # We only want the artifactId + local dependency=$(echo "${full_dependency}" | awk -F':' '{print $NF}') local version=$(echo "${dep_pair}" | cut -d'=' -f2 | sed 's/^[[:space:]]*//;s/[[:space:]]*$//') MAVEN_COMMAND+=" -D${dependency}.version=${version}" } diff --git a/java-shared-dependencies/third-party-dependencies/pom.xml b/java-shared-dependencies/third-party-dependencies/pom.xml index e7889ec483..e53c14d837 100644 --- a/java-shared-dependencies/third-party-dependencies/pom.xml +++ b/java-shared-dependencies/third-party-dependencies/pom.xml @@ -32,8 +32,8 @@ 1.18.0 4.4.16 4.5.14 - 5.3.1 5.2.5 + 5.3.1 3.49.0 0.27.0 @@ -83,7 +83,7 @@ org.apache.httpcomponents.client5 httpclient5 - ${httpclient5-5.version} + ${httpclient5.version} org.threeten From fe4915d6cff3eed09157e8ceba8ccc436873f63b Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Fri, 29 Aug 2025 15:41:24 -0400 Subject: [PATCH 04/16] chore: Revert back to original renovate.json --- renovate.json | 146 +++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 145 insertions(+), 1 deletion(-) diff --git a/renovate.json b/renovate.json index ea93b0b13a..f255fe17aa 100644 --- a/renovate.json +++ b/renovate.json @@ -72,6 +72,150 @@ ], "depNameTemplate": "com.google.cloud:google-cloud-shared-config", "datasourceTemplate": "maven" + }, + { + "customType": "regex", + "fileMatch": [ + "^.cloudbuild/library_generation/library_generation.*\\.Dockerfile$" + ], + "matchStrings": [ + "OWLBOT_CLI_COMMITTISH=(?.*?)\\n" + ], + "currentValueTemplate": "main", + "depNameTemplate": "repo-automation-bots", + "packageNameTemplate": "https://github.com/googleapis/repo-automation-bots", + "datasourceTemplate": "git-refs" + } + ], + "packageRules": [ + { + "matchPackageNames": [ + "com.google.cloud:google-cloud-shared-config" + ], + "registryUrls": [ + "https://repo.maven.apache.org/maven2/", + "https://repo1.maven.org/maven2" + ] + }, + { + "matchUpdateTypes": [ + "major" + ], + "enabled": false, + "matchPackageNames": [ + "*" + ] + }, + { + "enabled": false, + "matchPackageNames": [ + "/^com.google.protobuf:/" + ] + }, + { + "versioning": "docker", + "matchPackageNames": [ + "/^com.google.guava:/" + ], + "enabled": false + }, + { + "semanticCommitType": "deps", + "semanticCommitScope": null, + "matchPackageNames": [ + "*" + ] + }, + { + "semanticCommitType": "build", + "semanticCommitScope": "deps", + "enabled": true, + "matchPackageNames": [ + "/^org.apache.maven/", + "/^org.jacoco:/", + "/^org.codehaus.mojo:/", + "/^org.sonatype.plugins:/", + "/^com.google.cloud:google-cloud-shared-config/" + ] + }, + { + "semanticCommitType": "chore", + "semanticCommitScope": "deps", + "matchPackageNames": [ + "/^{{metadata['repo']['distribution_name']}}/", + "/^com.google.cloud:libraries-bom/", + "/^com.google.cloud.samples:shared-configuration/" + ] + }, + { + "semanticCommitType": "test", + "semanticCommitScope": "deps", + "matchPackageNames": [ + "/^junit:junit/", + "/^com.google.truth:truth/", + "/^org.mockito:mockito-core/", + "/^org.objenesis:objenesis/", + "/^com.google.cloud:google-cloud-conformance-tests/" + ] + }, + { + "ignoreUnstable": false, + "matchPackageNames": [ + "/^com.google.cloud:google-cloud-/" + ] + }, + { + "groupName": "jackson dependencies", + "matchPackageNames": [ + "/^com.fasterxml.jackson.core/" + ] + }, + { + "groupName": "gRPC dependencies", + "matchPackageNames": [ + "/^io.grpc/" + ], + "enabled": false + }, + { + "groupName": "Google Auth Library dependencies", + "matchPackageNames": [ + "/^com.google.auth/" + ] + }, + { + "groupName": "Google API dependencies", + "matchPackageNames": [ + "/com.google.api.grpc:grpc-google-common-protos/", + "/com.google.api.grpc:grpc-google-iam-v1/", + "/com.google.api.grpc:proto-google-common-protos/", + "/com.google.api.grpc:proto-google-iam-v1/", + "/com.google.api:api-common/" + ] + }, + { + "groupName": "Google HTTP Client dependencies", + "matchPackageNames": [ + "/^com.google.http-client/" + ] + }, + { + "groupName": "OpenCensus dependencies", + "matchPackageNames": [ + "/^io.opencensus/" + ] + }, + { + "groupName": "Netty dependencies", + "matchPackageNames": [ + "/^io.netty/" + ] + }, + { + "groupName": "Error Prone dependencies", + "matchPackageNames": [ + "/^com.google.errorprone/" + ] } ] -} +} \ No newline at end of file From a42349ba679543b3fc07e0c8bd0d604eb314881b Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Fri, 29 Aug 2025 15:59:58 -0400 Subject: [PATCH 05/16] chore: Fix 1P Google deps --- java-core/pom.xml | 2 +- java-shared-dependencies/first-party-dependencies/pom.xml | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/java-core/pom.xml b/java-core/pom.xml index 71c59688c9..7cbb55fd04 100644 --- a/java-core/pom.xml +++ b/java-core/pom.xml @@ -64,7 +64,7 @@ com.google.errorprone - error_prone_annotationsa + error_prone_annotations ${error_prone_annotations.version} diff --git a/java-shared-dependencies/first-party-dependencies/pom.xml b/java-shared-dependencies/first-party-dependencies/pom.xml index 608a712122..644a83bd63 100644 --- a/java-shared-dependencies/first-party-dependencies/pom.xml +++ b/java-shared-dependencies/first-party-dependencies/pom.xml @@ -23,8 +23,8 @@ UTF-8 ${project.artifactId} 1.6.1 - 1.39.0 - 2.7.2 + 1.39.0 + 2.7.2 @@ -52,14 +52,14 @@ com.google.oauth-client google-oauth-client-bom - ${google.google-oauth-client.version} + ${google-oauth-client.version} pom import com.google.api-client google-api-client-bom - ${google.google-api-client.version} + ${google-api-client.version} pom import From 6682d8476ee4b55d7f89d9e4877d2d4b5bb06aa9 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 11:01:10 -0400 Subject: [PATCH 06/16] chore: Add a pomProperty matcher in the dependencies.txt file --- .github/scripts/test_dependency_compatibility.sh | 6 +++--- renovate.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index 159fb3d078..9a3e28fde5 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -37,9 +37,9 @@ function add_dependency_to_maven_command() { exit 1 fi local full_dependency=$(echo "${dep_pair}" | cut -d'=' -f1 | tr -d '[:space:]') - # The dependency can be in the format of {groupId}:{artifactId} or {artifactId} - # We only want the artifactId - local dependency=$(echo "${full_dependency}" | awk -F':' '{print $NF}') + # The dependency can be in the format of {groupId}:{artifactId};{pomPropertyName} + # We only want the pomPropertyName + local dependency=$(echo "${full_dependency}" | awk -F';' '{print $NF}') local version=$(echo "${dep_pair}" | cut -d'=' -f2 | sed 's/^[[:space:]]*//;s/[[:space:]]*$//') MAVEN_COMMAND+=" -D${dependency}.version=${version}" } diff --git a/renovate.json b/renovate.json index f255fe17aa..a504a3adae 100644 --- a/renovate.json +++ b/renovate.json @@ -13,7 +13,7 @@ { "customType": "regex", "managerFilePatterns": ["/dependencies\\.txt/"], - "matchStrings": ["(?.*)=(?.*)\\n"], + "matchStrings": ["(?.*);(?.*)=(?.*)"], "datasourceTemplate": "maven" }, { From 74e2a159856c91dab7b130bcdcc29815b8eeacdc Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 11:18:29 -0400 Subject: [PATCH 07/16] chore: Reset pom properties names to original value --- ...ownstream-protobuf-source-compatibility.sh | 4 +- api-common-java/pom.xml | 2 +- gapic-generator-java-bom/pom.xml | 10 +-- gapic-generator-java/pom.xml | 4 +- gax-java/pom.xml | 12 +-- java-common-protos/pom.xml | 4 +- java-core/pom.xml | 4 +- java-iam/pom.xml | 4 +- .../first-party-dependencies/pom.xml | 8 +- .../third-party-dependencies/pom.xml | 80 +++++++++---------- renovate.json | 8 +- 11 files changed, 67 insertions(+), 73 deletions(-) diff --git a/.kokoro/nightly/downstream-protobuf-source-compatibility.sh b/.kokoro/nightly/downstream-protobuf-source-compatibility.sh index 62b7795ba1..aaa65b8208 100755 --- a/.kokoro/nightly/downstream-protobuf-source-compatibility.sh +++ b/.kokoro/nightly/downstream-protobuf-source-compatibility.sh @@ -48,7 +48,7 @@ for repo in ${REPOS_UNDER_TEST//,/ }; do # Split on comma -Denforcer.skip \ -Dmaven.javadoc.skip \ -Denforcer.skip \ - -Dprotobuf-java.version=${PROTOBUF_RUNTIME_VERSION} \ + -Dprotobuf.version=${PROTOBUF_RUNTIME_VERSION} \ -pl "${google_cloud_java_handwritten_maven_args}" -am \ "${surefire_opt}" \ -T 1C @@ -58,7 +58,7 @@ for repo in ${REPOS_UNDER_TEST//,/ }; do # Split on comma -Denforcer.skip \ -Dmaven.javadoc.skip \ -Denforcer.skip \ - -Dprotobuf-java.version=${PROTOBUF_RUNTIME_VERSION} \ + -Dprotobuf.version=${PROTOBUF_RUNTIME_VERSION} \ "${surefire_opt}" \ -T 1C fi diff --git a/api-common-java/pom.xml b/api-common-java/pom.xml index 6236d450ca..997184e27e 100644 --- a/api-common-java/pom.xml +++ b/api-common-java/pom.xml @@ -63,7 +63,7 @@ com.google.errorprone error_prone_annotations - ${error_prone_annotations.version} + ${errorprone.version} compile diff --git a/gapic-generator-java-bom/pom.xml b/gapic-generator-java-bom/pom.xml index dfef2cef15..9eaa0b3a80 100644 --- a/gapic-generator-java-bom/pom.xml +++ b/gapic-generator-java-bom/pom.xml @@ -25,14 +25,14 @@ com.google.auth google-auth-library-bom - ${google-auth-library-bom.version} + ${google.auth.version} pom import com.google.auth google-auth-library-oauth2-http - ${google-auth-library-bom.version} + ${google.auth.version} test-jar testlib test @@ -40,7 +40,7 @@ com.google.http-client google-http-client-bom - ${google-http-client.version} + ${google.http-client.version} pom import @@ -59,14 +59,14 @@ com.google.protobuf protobuf-bom - ${protobuf-java.version} + ${protobuf.version} pom import io.grpc grpc-bom - ${grpc-bom.version} + ${grpc.version} pom import diff --git a/gapic-generator-java/pom.xml b/gapic-generator-java/pom.xml index 8d742fa2bd..84d579d85b 100644 --- a/gapic-generator-java/pom.xml +++ b/gapic-generator-java/pom.xml @@ -247,7 +247,7 @@ 0.6.1 - com.google.protobuf:protoc:${protobuf-java.version}:exe:${os.detected.classifier} + com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier} @@ -450,7 +450,7 @@ com.google.errorprone error_prone_annotations - ${error_prone_annotations.version} + ${errorprone.version} 3.49.0 0.27.0 3.0.0 - 0.33.0 + 0.33.0 2.1.0-alpha 1.29.0-alpha 0.8 - 17.0.0 - 0.6.0 - 1.16.0 - 1.45.0-alpha + 17.0.0 + 0.6.0 + 1.16.0 + 1.45.0-alpha @@ -53,37 +53,37 @@ org.apache.arrow arrow-memory-core - ${arrow-memory-core.version} + ${arrow.version} org.apache.arrow arrow-memory-netty - ${arrow-memory-core.version} + ${arrow.version} org.apache.arrow arrow-vector - ${arrow-memory-core.version} + ${arrow.version} org.apache.httpcomponents httpcore - ${httpcore.version} + ${httpcomponents.httpcore.version} org.apache.httpcomponents httpclient - ${httpclient.version} + ${httpcomponents.httpclient.version} org.apache.httpcomponents.core5 httpcore5 - ${httpcore5.version} + ${apache-httpcore-5.version} org.apache.httpcomponents.client5 httpclient5 - ${httpclient5.version} + ${apache-httpclient-5.version} org.threeten @@ -109,12 +109,12 @@ com.google.code.findbugs jsr305 - ${jsr305.version} + ${findbugs.version} com.google.errorprone error_prone_annotations - ${error_prone_annotations.version} + ${errorprone.version} @@ -131,19 +131,19 @@ com.fasterxml.jackson jackson-bom - ${jackson-bom.version} + ${jackson.version} pom import commons-codec commons-codec - ${commons-codec.version} + ${codec.version} io.opentelemetry opentelemetry-bom - ${opentelemetry-bom.version} + ${opentelemetry.version} pom import @@ -167,59 +167,59 @@ com.google.cloud.opentelemetry exporter-metrics - ${exporter-metrics.version} + ${google.cloud.opentelemetry.version} com.google.cloud.opentelemetry shared-resourcemapping - ${exporter-metrics.version} + ${google.cloud.opentelemetry.version} io.opentelemetry.contrib opentelemetry-gcp-resources - ${opentelemetry-gcp-resources.version} + ${io.opentelemetry.contrib.opentelemetry-gcp-resources.version} io.opencensus opencensus-api - ${opencensus-api.version} + ${opencensus.version} io.opencensus opencensus-contrib-grpc-util - ${opencensus-api.version} + ${opencensus.version} io.opencensus opencensus-contrib-http-util - ${opencensus-api.version} + ${opencensus.version} io.opencensus opencensus-contrib-zpages - ${opencensus-api.version} + ${opencensus.version} io.opencensus opencensus-exporter-stats-stackdriver - ${opencensus-api.version} + ${opencensus.version} io.opencensus opencensus-exporter-trace-stackdriver - ${opencensus-api.version} + ${opencensus.version} io.opencensus opencensus-impl - ${opencensus-api.version} + ${opencensus.version} io.opencensus opencensus-impl-core - ${opencensus-api.version} + ${opencensus.version} org.checkerframework @@ -239,7 +239,7 @@ com.google.cloud.opentelemetry detector-resources-support - ${exporter-metrics.version} + ${google.cloud.opentelemetry.version} org.junit @@ -251,12 +251,12 @@ dev.cel cel - ${cel.version} + ${dev.cel.version} com.google.crypto.tink tink - ${tink.version} + ${com.google.crypto.tink.version} diff --git a/renovate.json b/renovate.json index a504a3adae..ee4e763c36 100644 --- a/renovate.json +++ b/renovate.json @@ -10,12 +10,6 @@ "^library_generation/requirements\\.txt$" ], "customManagers": [ - { - "customType": "regex", - "managerFilePatterns": ["/dependencies\\.txt/"], - "matchStrings": ["(?.*);(?.*)=(?.*)"], - "datasourceTemplate": "maven" - }, { "customType": "regex", "fileMatch": [ @@ -218,4 +212,4 @@ ] } ] -} \ No newline at end of file +} From 4e8bcf14eaa8b66a7c800adfc707eaf2028a8b13 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 11:42:53 -0400 Subject: [PATCH 08/16] chore: update dependencies.txt file to a new format --- .github/scripts/test_dependency_compatibility.sh | 12 +++++------- renovate.json | 10 ++++++++++ 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index 9a3e28fde5..46293868f3 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -32,15 +32,13 @@ function print_help() { # Function to parse a dependency string and append it to the Maven command function add_dependency_to_maven_command() { local dep_pair=$1 - if [[ ! "${dep_pair}" =~ .*=.* ]]; then - echo "Malformed dependency string: ${dep_pair}. Expected format: dependency=version" + if [[ ! "${dep_pair}" =~ .*:.*:.* ]]; then + echo "Malformed dependency string: ${dep_pair}. Expected format: {GroupID}:{ArtifactID}:{Version}:{MavenPropertyName}" exit 1 fi - local full_dependency=$(echo "${dep_pair}" | cut -d'=' -f1 | tr -d '[:space:]') - # The dependency can be in the format of {groupId}:{artifactId};{pomPropertyName} - # We only want the pomPropertyName - local dependency=$(echo "${full_dependency}" | awk -F';' '{print $NF}') - local version=$(echo "${dep_pair}" | cut -d'=' -f2 | sed 's/^[[:space:]]*//;s/[[:space:]]*$//') + local full_dependency=$(echo "${dep_pair}" | rev | cut -d':' -f2- | rev) + local dependency=$(echo "${dep_pair}" | rev | cut -d':' -f1 | rev) + local version=$(echo "${full_dependency}" | awk -F':' '{print $NF}') MAVEN_COMMAND+=" -D${dependency}.version=${version}" } diff --git a/renovate.json b/renovate.json index ee4e763c36..fd27fc2335 100644 --- a/renovate.json +++ b/renovate.json @@ -10,6 +10,16 @@ "^library_generation/requirements\\.txt$" ], "customManagers": [ + { + "customType": "regex", + "fileMatch": [ + "^dependencies\\.txt$" + ], + "matchStrings": [ + "^(?[^:]+:[^:]+):(?[^:]+):(?[^:]+?)$" + ], + "datasourceTemplate": "maven" + }, { "customType": "regex", "fileMatch": [ From b3693a62b3d0fe63c407137ae321263a5dd8d086 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 12:00:41 -0400 Subject: [PATCH 09/16] chore: Simplify script --- .../scripts/test_dependency_compatibility.sh | 23 +++++++------------ 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index 46293868f3..c175618303 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -29,19 +29,6 @@ function print_help() { echo "Use -l {deps_list} for a comma-separated list of dependencies to test (Format: dep1=1.0,dep2=2.0)" } -# Function to parse a dependency string and append it to the Maven command -function add_dependency_to_maven_command() { - local dep_pair=$1 - if [[ ! "${dep_pair}" =~ .*:.*:.* ]]; then - echo "Malformed dependency string: ${dep_pair}. Expected format: {GroupID}:{ArtifactID}:{Version}:{MavenPropertyName}" - exit 1 - fi - local full_dependency=$(echo "${dep_pair}" | rev | cut -d':' -f2- | rev) - local dependency=$(echo "${dep_pair}" | rev | cut -d':' -f1 | rev) - local version=$(echo "${full_dependency}" | awk -F':' '{print $NF}') - MAVEN_COMMAND+=" -D${dependency}.version=${version}" -} - # Default to the upper bounds file in the root of the repo file='dependencies.txt' dependency_list='' @@ -78,7 +65,10 @@ if [ -z "${dependency_list}" ]; then if [[ "${line}" =~ ^[[:space:]]*# ]] || [[ -z "${line}" ]]; then continue fi - add_dependency_to_maven_command "${line}" + # Format from `dependencies.txt`: {GroupID}:{ArtifactID}:{Version}:{MavenPropertyName} + dependency=$(echo "${line}" | cut -d':' -f4) + version=$(echo "${line}" | cut -d':' -f3) + MAVEN_COMMAND+=" -D${dependency}.version=${version}" done < "${UPPER_BOUND_DEPENDENCY_FILE}" else # This else block means that a list of dependencies was inputted # Set the Internal Field Separator (IFS) to a comma. @@ -92,7 +82,10 @@ else # This else block means that a list of dependencies was inputted if [ -z "${DEP_PAIR}" ]; then continue fi - add_dependency_to_maven_command "${DEP_PAIR}" + # Format: {MavenPropertyName}:{Version} + dependency=$(echo "${DEP_PAIR}" | cut -d':' -f1) + version=$(echo "${DEP_PAIR}" | cut -d':' -f2) + MAVEN_COMMAND+=" -D${dependency}.version=${version}" done fi From 5bcc0fc51a38d4b35db6155532ebf250739a02bc Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 12:12:51 -0400 Subject: [PATCH 10/16] chore: Update description of new format --- .github/scripts/test_dependency_compatibility.sh | 2 +- .github/workflows/dependency_compatibility_test.yaml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index c175618303..732741f581 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -47,7 +47,7 @@ if [[ -z "${file}" && -z "${dependency_list}" ]]; then print_help && exit 1 fi -MAVEN_COMMAND="mvn verify -Penable-integration-tests -Dclirr.skip -Dcheckstyle.skip -Dfmt.skip -Denforcer.skip " +MAVEN_COMMAND="mvn -ntp -B verify -Penable-integration-tests -Dclirr.skip -Dcheckstyle.skip -Dfmt.skip -Denforcer.skip" # Check if a list of dependencies was provided as an argument. If the list of dependency inputted # is empty, then run with the upper-bound dependencies file diff --git a/.github/workflows/dependency_compatibility_test.yaml b/.github/workflows/dependency_compatibility_test.yaml index f13ce1e0cf..ca5771c66c 100644 --- a/.github/workflows/dependency_compatibility_test.yaml +++ b/.github/workflows/dependency_compatibility_test.yaml @@ -7,7 +7,8 @@ on: workflow_dispatch: inputs: dependencies-list: - description: 'Comma-separated list of dependencies to test (Example format: protobuf=4.31.0,guava=33.4.8-jre). + description: 'Comma-separated list of dependencies to test (Example format: protobuf:4.31.0,guava:33.4.8-jre). + Note: The name should be the maven property. Find this value in the section in the pom. Do not include the `-D` prefix or `.version` suffix. Those values will be appended when generating the command. No input (default) will run the the upper-bound dependencies file.' required: false From ba9bb671c4cb6472456389872a35fbb7d424fffc Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 12:19:09 -0400 Subject: [PATCH 11/16] chore: Fix pom format issues --- gapic-generator-java-pom-parent/pom.xml | 414 ++++++++++++------------ 1 file changed, 207 insertions(+), 207 deletions(-) diff --git a/gapic-generator-java-pom-parent/pom.xml b/gapic-generator-java-pom-parent/pom.xml index d04eeeb91e..0eba4c4640 100644 --- a/gapic-generator-java-pom-parent/pom.xml +++ b/gapic-generator-java-pom-parent/pom.xml @@ -1,217 +1,217 @@ - 4.0.0 - com.google.api - gapic-generator-java-pom-parent - 2.62.4-SNAPSHOT - pom - GAPIC Generator Java POM Parent - https://github.com/googleapis/sdk-platform-java - - The top-level parent for all modules in the repository. - - - com.google.cloud - google-cloud-shared-config - 1.16.1 - - + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" child.project.url.inherit.append.path="false"> + 4.0.0 + com.google.api + gapic-generator-java-pom-parent + 2.62.4-SNAPSHOT + pom + GAPIC Generator Java POM Parent + https://github.com/googleapis/sdk-platform-java + + The top-level parent for all modules in the repository. + + + com.google.cloud + google-cloud-shared-config + 1.16.1 + + - - false - java.header + + false + java.header + 8 - - 1.3.2 - 1.71.0 - 1.39.1 - 1.47.1 - 2.12.1 - 33.4.0-jre - 3.25.8 - 1.47.0 - 8 - 2.38.0 - 3.0.0 - 1.7.0 - 5.11.4 - 4.11.0 - 2.0.16 - + + 1.3.2 + 1.71.0 + 1.39.1 + 1.47.1 + 2.12.1 + 33.4.0-jre + 3.25.8 + 1.47.0 + 2.38.0 + 3.0.0 + 1.7.0 + 5.11.4 + 4.11.0 + 2.0.16 + - - - suztomo - Tomo Suzuki - suztomo@google.com - Google - - Developer - - - - - Google LLC - - - scm:git:git@github.com:googleapis/sdk-platform-java.git - scm:git:git@github.com:googleapis/sdk-platform-java.git - https://github.com/googleapis/sdk-platform-java - HEAD - - - https://github.com/googleapis/sdk-platform-java/issues - GitHub Issues - + + + suztomo + Tomo Suzuki + suztomo@google.com + Google + + Developer + + + + + Google LLC + + + scm:git:git@github.com:googleapis/sdk-platform-java.git + scm:git:git@github.com:googleapis/sdk-platform-java.git + https://github.com/googleapis/sdk-platform-java + HEAD + + + https://github.com/googleapis/sdk-platform-java/issues + GitHub Issues + - - - Apache-2.0 - https://www.apache.org/licenses/LICENSE-2.0.txt - - + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0.txt + + - - - - checkstyle-tests - - [11,) - - - - - org.apache.maven.plugins - maven-checkstyle-plugin - - - checkstyle - validate - - check - - - ${checkstyle.header.file} - - - - - - - + + + + checkstyle-tests + + [11,) + + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + + checkstyle + validate + + check + + + ${checkstyle.header.file} + + + + + + + - - test-coverage - - - enableShowcaseTestCoverage - - - - - - - org.apache.maven.plugins - maven-surefire-plugin - 3.5.2 - - - - **/*SmokeTest.java - **/IT*.java - - sponge_log - ${surefire.jacoco.args} - ${skipUnitTests} - - + + test-coverage + + + enableShowcaseTestCoverage + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + 3.5.2 + + + + **/*SmokeTest.java + **/IT*.java + + sponge_log + ${surefire.jacoco.args} + ${skipUnitTests} + + - - org.apache.maven.plugins - maven-failsafe-plugin - 3.5.2 - - - - integration-test - verify - - - - - 3600 - sponge_log - - **/IT*.java - **/*SmokeTest.java - - ${failsafe.jacoco.args} - - - - - - - org.jacoco - jacoco-maven-plugin - 0.8.13 - - - unit-test-execution - - prepare-agent - - - surefire.jacoco.args - - - - integration-test-execution - pre-integration-test - - prepare-agent - - - failsafe.jacoco.args - - - - - - - - - envVarTest - - - - org.apache.maven.plugins - maven-surefire-plugin - - - - **/*.java - - - - - - - - - - google-maven-central-copy - Google Maven Central copy - https://maven-central.storage-download.googleapis.com/maven2 - - - maven-central - Maven Central - https://repo1.maven.org/maven2 - - + + org.apache.maven.plugins + maven-failsafe-plugin + 3.5.2 + + + + integration-test + verify + + + + + 3600 + sponge_log + + **/IT*.java + **/*SmokeTest.java + + ${failsafe.jacoco.args} + + + + + + + org.jacoco + jacoco-maven-plugin + 0.8.13 + + + unit-test-execution + + prepare-agent + + + surefire.jacoco.args + + + + integration-test-execution + pre-integration-test + + prepare-agent + + + failsafe.jacoco.args + + + + + + + + + envVarTest + + + + org.apache.maven.plugins + maven-surefire-plugin + + + + **/*.java + + + + + + + + + + google-maven-central-copy + Google Maven Central copy + https://maven-central.storage-download.googleapis.com/maven2 + + + maven-central + Maven Central + https://repo1.maven.org/maven2 + + \ No newline at end of file From 713523bb44e48a78ff45907714cebe2c0511acb1 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 13:29:29 -0400 Subject: [PATCH 12/16] chore: Update the scripts --- .github/scripts/test_dependency_compatibility.sh | 7 +++---- .github/workflows/dependency_compatibility_test.yaml | 4 ++-- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index 732741f581..c71e37dd70 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -9,7 +9,7 @@ # upper-bounds dependency file at the root of the repo. # There are two potential inputs to the script: # 1. -f {file}: Custom file/path for the upper-bound dependencies to test -# 2. -l {deps_list}: Comma-separated list of dependencies to test (e.g. protobuf=4.31.0,guava=33.4.8-jre) +# 2. -l {deps_list}: Comma-separated list of dependencies to test (e.g. protobuf:4.31.0,guava:33.4.8-jre) # Note: Do not include the `-D` prefix or `.version` suffix. Those values will be appended when generating # the maven command. # @@ -18,15 +18,14 @@ # an input for the deps_list to manually run a subset of dependencies. # # The default upper-bound dependencies file is `dependencies.txt` located in the root -# of sdk-platform-java. The upper-bound dependencies file will be in the format of: -# {groupId}:{artifactId}={version} or {artifactId}={version} +# of sdk-platform-java. See the upper-bound dependencies file for the dependency format. set -ex function print_help() { echo "Unexpected input argument for this script." echo "Use -f {file} for the directory of the upper-bound dependencies file." - echo "Use -l {deps_list} for a comma-separated list of dependencies to test (Format: dep1=1.0,dep2=2.0)" + echo "Use -l {deps_list} for a comma-separated list of dependencies to test (Format: dep1:1.0,dep2:2.0)" } # Default to the upper bounds file in the root of the repo diff --git a/.github/workflows/dependency_compatibility_test.yaml b/.github/workflows/dependency_compatibility_test.yaml index ca5771c66c..f9a51dba5e 100644 --- a/.github/workflows/dependency_compatibility_test.yaml +++ b/.github/workflows/dependency_compatibility_test.yaml @@ -35,7 +35,7 @@ jobs: run: echo "DEPENDENCIES_LIST=${{ github.event.inputs.dependencies-list }}" >> $GITHUB_ENV # Run in the root module which should test for everything except for showcase - - name: Perform Dependency Compatibility Testing + - name: Perform Dependency Compatibility Unit Testing shell: bash run: | if [[ -n "${{ env.DEPENDENCIES_LIST }}" ]]; then @@ -64,7 +64,7 @@ jobs: cd - # Run Showcase's Integration Tests - - name: Perform Dependency Compatibility Testing (Showcase only) + - name: Perform Dependency Compatibility Integration Testing (Showcase Tests) shell: bash # Need to cd out of the directory to get the scripts as this step is run inside the java-showcase directory run: | From f27e3014bdcb67de96b8cb742e0dfc3064c482c2 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 14:05:17 -0400 Subject: [PATCH 13/16] chore: Update to new dependencies.txt file --- .../scripts/test_dependency_compatibility.sh | 13 +- .../dependency_compatibility_test.yaml | 2 +- dependencies.txt | 66 ++--- renovate.json | 236 +++--------------- 4 files changed, 70 insertions(+), 247 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index c71e37dd70..90c90e796c 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -64,9 +64,10 @@ if [ -z "${dependency_list}" ]; then if [[ "${line}" =~ ^[[:space:]]*# ]] || [[ -z "${line}" ]]; then continue fi - # Format from `dependencies.txt`: {GroupID}:{ArtifactID}:{Version}:{MavenPropertyName} - dependency=$(echo "${line}" | cut -d':' -f4) - version=$(echo "${line}" | cut -d':' -f3) + # Format from `dependencies.txt`: {GroupID}:{ArtifactID},{PropertyName}={Version} + version=$(echo "${line}" | cut -d'=' -f2) + dependency_and_group_artifact=$(echo "${line}" | cut -d'=' -f1) + dependency=$(echo "${dependency_and_group_artifact}" | cut -d',' -f2) MAVEN_COMMAND+=" -D${dependency}.version=${version}" done < "${UPPER_BOUND_DEPENDENCY_FILE}" else # This else block means that a list of dependencies was inputted @@ -81,9 +82,9 @@ else # This else block means that a list of dependencies was inputted if [ -z "${DEP_PAIR}" ]; then continue fi - # Format: {MavenPropertyName}:{Version} - dependency=$(echo "${DEP_PAIR}" | cut -d':' -f1) - version=$(echo "${DEP_PAIR}" | cut -d':' -f2) + # Format: {MavenPropertyName}={Version} + dependency=$(echo "${DEP_PAIR}" | cut -d'=' -f1) + version=$(echo "${DEP_PAIR}" | cut -d'=' -f2) MAVEN_COMMAND+=" -D${dependency}.version=${version}" done fi diff --git a/.github/workflows/dependency_compatibility_test.yaml b/.github/workflows/dependency_compatibility_test.yaml index f9a51dba5e..e1b5203fac 100644 --- a/.github/workflows/dependency_compatibility_test.yaml +++ b/.github/workflows/dependency_compatibility_test.yaml @@ -7,7 +7,7 @@ on: workflow_dispatch: inputs: dependencies-list: - description: 'Comma-separated list of dependencies to test (Example format: protobuf:4.31.0,guava:33.4.8-jre). + description: 'Comma-separated list of dependencies to test (Example format: protobuf=4.31.0,guava=33.4.8-jre). Note: The name should be the maven property. Find this value in the section in the pom. Do not include the `-D` prefix or `.version` suffix. Those values will be appended when generating the command. No input (default) will run the the upper-bound dependencies file.' diff --git a/dependencies.txt b/dependencies.txt index b9d9be0a6a..edced62da7 100644 --- a/dependencies.txt +++ b/dependencies.txt @@ -1,5 +1,5 @@ # This file contains a list of dependencies and their versions to be tested for compatibility. -# The format is `{GroupID}:{ArtifactID}:{Version}:{MavenPropertyName}`. The GAV coordinates +# The format is `{GroupID}:{ArtifactID},{PropertyName}={Version}`. The GAV coordinates # (specifically the GroupID and ArtifactID are parsed by renovate to find the artifact from Maven # Central. Version stores the currently known upper bound. MavenPropertyName corresponds to the # Maven property value in the pom.xml (it is not a 1:1 mapping to the GAV). @@ -8,43 +8,43 @@ # Pom-Parent Dependencies # These dependencies are declared: https://github.com/googleapis/sdk-platform-java/blob/main/gapic-generator-java-pom-parent/pom.xml -javax.annotation:javax.annotation-api:1.3.2:javax.annotation-api -io.grpc:grpc-bom:1.74.0:grpc -com.google.auth:google.google-auth-library-bom:1.37.1:google.auth -com.google.http-client:google-http-client:1.47.1:google.http-client -com.google.code.gson:gson:2.13.1:gson -com.google.guava:guava:33.4.8-jre:guava -com.google.protobuf:protobuf-java:4.31.1:protobuf -io.opentelemetry:opentelemetry-bom:1.52.0:opentelemetry -com.google.errorprone:error_prone_annotations:2.41.0:errorprone -com.google.j2objc:j2objc-annotations:3.1:j2objc-annotations -org.threeten:threetenbp:1.7.2:threetenbp -org.slf4j:slf4j-api:2.0.17:slf4j +javax.annotation:javax.annotation-api,javax.annotation-api=1.3.2 +io.grpc:grpc-bom,grpc=1.74.0 +com.google.auth:google.google-auth-library-bom,google.auth=1.37.1 +com.google.http-client:google-http-client,google.http-client=1.47.1 +com.google.code.gson:gson,gson=2.13.1 +com.google.guava:guava,guava=33.4.8-jre +com.google.protobuf:protobuf-java,protobuf=4.31.1 +io.opentelemetry:opentelemetry-bom,opentelemetry=1.52.0 +com.google.errorprone:error_prone_annotations,errorprone=2.41.0 +com.google.j2objc:j2objc-annotations,j2objc-annotations=3.1 +org.threeten:threetenbp,threetenbp=1.7.2 +org.slf4j:slf4j-api,slf4j=2.0.17 # 1P Shared-Deps # These dependencies are declared: https://github.com/googleapis/sdk-platform-java/blob/main/java-shared-dependencies/first-party-dependencies/pom.xml -com.google.cloud:grpc-gcp:1.6.1:grpc-gcp -com.google.oauth-client:google-oauth-client:1.39.0:google.oauth-client -com.google.api-client:google-api-client:2.8.1:google.api-client +com.google.cloud:grpc-gcp,grpc-gcp=1.6.1 +com.google.oauth-client:google-oauth-client,google.oauth-client=1.39.0 +com.google.api-client:google-api-client,google.api-client=2.8.1 # 3P Shared-Deps # These dependencies are declared: https://github.com/googleapis/sdk-platform-java/blob/main/java-shared-dependencies/third-party-dependencies/pom.xml -org.threeten:threeten-extra:1.8.0:threeten-extra -io.opencensus:opencensus-api:0.31.0:opencensus -com.google.code.findbugs:jsr305:3.0.2:findbugs -com.fasterxml.jackson:jackson-bom:2.19.2:jackson -commons-codec:commons-codec:1.19.0:codec -org.apache.httpcomponents:httpclient:4.5.14:httpcomponents.httpclient -org.apache.httpcomponents:httpcore:4.4.16:httpcomponents.httpcore -org.apache.httpcomponents.client5:httpclient5:5.5:apache-httpclient-5 -org.apache.httpcomponents.core5:httpcore5:5.3.4:apache-httpcore-5 -io.perfmark:perfmark-api:0.27.0:perfmark-api +org.threeten:threeten-extra,threeten-extra=1.8.0 +io.opencensus:opencensus-api,opencensus=0.31.0 +com.google.code.findbugs:jsr305,findbugs=3.0.2 +com.fasterxml.jackson:jackson-bom,jackson=2.19.2 +commons-codec:commons-codec,codec=1.19.0 +org.apache.httpcomponents:httpclient,httpcomponents.httpclient=4.5.14 +org.apache.httpcomponents:httpcore,httpcomponents.httpcore=4.4.16 +org.apache.httpcomponents.client5:httpclient5,apache-httpclient-5=5.5 +org.apache.httpcomponents.core5:httpcore5,apache-httpcore-5=5.3.4 +io.perfmark:perfmark-api,perfmark-api=0.27.0 # Note: This is the google opentelemetry exporter and not the general opentelemetry project -com.google.cloud.opentelemetry:exporter-metrics:0.36.0:google.cloud.opentelemetry -com.google.flogger:flogger:0.9:flogger -org.apache.arrow:arrow-memory-core:18.3.0:arrow -dev.cel:cel:0.10.1:dev.cel -com.google.crypto.tink:tink:1.18.0:com.google.crypto.tink +com.google.cloud.opentelemetry:exporter-metrics,google.cloud.opentelemetry=0.36.0 +com.google.flogger:flogger,flogger=0.9 +org.apache.arrow:arrow-memory-core,arrow=18.3.0 +dev.cel:cel,dev.cel=0.10.1 +com.google.crypto.tink:tink,com.google.crypto.tink=1.18.0 # The follow opentelemetry dependencies have a different version from the opentelemetry-bom -io.opentelemetry.semconv:opentelemetry-semconv:1.34.0:opentelemetry-semconv -io.opentelemetry.contrib:opentelemetry-gcp-resources:1.48.0-alpha:io.opentelemetry.contrib.opentelemetry-gcp-resources \ No newline at end of file +io.opentelemetry.semconv:opentelemetry-semconv,opentelemetry-semconv=1.34.0 +io.opentelemetry.contrib:opentelemetry-gcp-resources,io.opentelemetry.contrib.opentelemetry-gcp-resources=1.48.0-alpha diff --git a/renovate.json b/renovate.json index fd27fc2335..e16d2dcb2e 100644 --- a/renovate.json +++ b/renovate.json @@ -9,217 +9,39 @@ "ignorePaths": [ "^library_generation/requirements\\.txt$" ], + "bazel": { + "enabled": false + }, + "cloudbuild": { + "enabled": false + }, + "dockerfile": { + "enabled": false + }, + "gradle": { + "enabled": false + }, + "gradle-wrapper": { + "enabled": false + }, + "maven": { + "enabled": false + }, + "pip_setup": { + "enabled": false + }, + "pip_requirements": { + "enabled": false + }, + "github-actions": { + "enabled": false + }, "customManagers": [ { "customType": "regex", - "fileMatch": [ - "^dependencies\\.txt$" - ], - "matchStrings": [ - "^(?[^:]+:[^:]+):(?[^:]+):(?[^:]+?)$" - ], + "managerFilePatterns": ["/^dependencies\\.txt$/"], + "matchStrings": ["(?.*),(.*)=(?.*)"], "datasourceTemplate": "maven" - }, - { - "customType": "regex", - "fileMatch": [ - "^gax-java/dependencies\\.properties$" - ], - "matchStrings": [ - "=(?.+\\:.+?):(?.+?)\\n" - ], - "datasourceTemplate": "maven" - }, - { - "customType": "regex", - "fileMatch": [ - "^gax-java/dependencies\\.properties$" - ], - "matchStrings": [ - "version\\.google_java_format=(?.+?)\\n" - ], - "depNameTemplate": "com.google.googlejavaformat:google-java-format", - "datasourceTemplate": "maven" - }, - { - "customType": "regex", - "fileMatch": [ - "^gax-java/dependencies\\.properties$", - "^\\.cloudbuild/library_generation/library_generation.*\\.Dockerfile$" - ], - "matchStrings": [ - "version\\.io_grpc=(?.+?)\\n", - "ARG GRPC_VERSION=[\"']?(?.+?)[\"']?\\s+" - ], - "depNameTemplate": "io.grpc:grpc-core", - "datasourceTemplate": "maven" - }, - { - "customType": "regex", - "fileMatch": [ - "^.kokoro/presubmit/graalvm-native.*.cfg$" - ], - "matchStrings": [ - "value: \"gcr.io/cloud-devrel-kokoro-resources/graalvm:(?.*?)\"", - "value: \"gcr.io/cloud-devrel-kokoro-resources/graalvm17:(?.*?)\"" - ], - "depNameTemplate": "ghcr.io/graalvm/graalvm-ce", - "datasourceTemplate": "docker" - }, - { - "customType": "regex", - "fileMatch": [ - "^.cloudbuild/*" - ], - "matchStrings": [ - " _JAVA_SHARED_CONFIG_VERSION: '(?.+?)'" - ], - "depNameTemplate": "com.google.cloud:google-cloud-shared-config", - "datasourceTemplate": "maven" - }, - { - "customType": "regex", - "fileMatch": [ - "^.cloudbuild/library_generation/library_generation.*\\.Dockerfile$" - ], - "matchStrings": [ - "OWLBOT_CLI_COMMITTISH=(?.*?)\\n" - ], - "currentValueTemplate": "main", - "depNameTemplate": "repo-automation-bots", - "packageNameTemplate": "https://github.com/googleapis/repo-automation-bots", - "datasourceTemplate": "git-refs" - } - ], - "packageRules": [ - { - "matchPackageNames": [ - "com.google.cloud:google-cloud-shared-config" - ], - "registryUrls": [ - "https://repo.maven.apache.org/maven2/", - "https://repo1.maven.org/maven2" - ] - }, - { - "matchUpdateTypes": [ - "major" - ], - "enabled": false, - "matchPackageNames": [ - "*" - ] - }, - { - "enabled": false, - "matchPackageNames": [ - "/^com.google.protobuf:/" - ] - }, - { - "versioning": "docker", - "matchPackageNames": [ - "/^com.google.guava:/" - ], - "enabled": false - }, - { - "semanticCommitType": "deps", - "semanticCommitScope": null, - "matchPackageNames": [ - "*" - ] - }, - { - "semanticCommitType": "build", - "semanticCommitScope": "deps", - "enabled": true, - "matchPackageNames": [ - "/^org.apache.maven/", - "/^org.jacoco:/", - "/^org.codehaus.mojo:/", - "/^org.sonatype.plugins:/", - "/^com.google.cloud:google-cloud-shared-config/" - ] - }, - { - "semanticCommitType": "chore", - "semanticCommitScope": "deps", - "matchPackageNames": [ - "/^{{metadata['repo']['distribution_name']}}/", - "/^com.google.cloud:libraries-bom/", - "/^com.google.cloud.samples:shared-configuration/" - ] - }, - { - "semanticCommitType": "test", - "semanticCommitScope": "deps", - "matchPackageNames": [ - "/^junit:junit/", - "/^com.google.truth:truth/", - "/^org.mockito:mockito-core/", - "/^org.objenesis:objenesis/", - "/^com.google.cloud:google-cloud-conformance-tests/" - ] - }, - { - "ignoreUnstable": false, - "matchPackageNames": [ - "/^com.google.cloud:google-cloud-/" - ] - }, - { - "groupName": "jackson dependencies", - "matchPackageNames": [ - "/^com.fasterxml.jackson.core/" - ] - }, - { - "groupName": "gRPC dependencies", - "matchPackageNames": [ - "/^io.grpc/" - ], - "enabled": false - }, - { - "groupName": "Google Auth Library dependencies", - "matchPackageNames": [ - "/^com.google.auth/" - ] - }, - { - "groupName": "Google API dependencies", - "matchPackageNames": [ - "/com.google.api.grpc:grpc-google-common-protos/", - "/com.google.api.grpc:grpc-google-iam-v1/", - "/com.google.api.grpc:proto-google-common-protos/", - "/com.google.api.grpc:proto-google-iam-v1/", - "/com.google.api:api-common/" - ] - }, - { - "groupName": "Google HTTP Client dependencies", - "matchPackageNames": [ - "/^com.google.http-client/" - ] - }, - { - "groupName": "OpenCensus dependencies", - "matchPackageNames": [ - "/^io.opencensus/" - ] - }, - { - "groupName": "Netty dependencies", - "matchPackageNames": [ - "/^io.netty/" - ] - }, - { - "groupName": "Error Prone dependencies", - "matchPackageNames": [ - "/^com.google.errorprone/" - ] } ] } From f6f51bd55cd0fda987cf671f3da74bb01a82e1f1 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 14:43:16 -0400 Subject: [PATCH 14/16] chore: Fix deps format --- dependencies.txt | 2 +- renovate.json | 218 +++++++++++++++++++++++++++++++++++++++++------ 2 files changed, 192 insertions(+), 28 deletions(-) diff --git a/dependencies.txt b/dependencies.txt index edced62da7..9cc580e6ec 100644 --- a/dependencies.txt +++ b/dependencies.txt @@ -10,7 +10,7 @@ # These dependencies are declared: https://github.com/googleapis/sdk-platform-java/blob/main/gapic-generator-java-pom-parent/pom.xml javax.annotation:javax.annotation-api,javax.annotation-api=1.3.2 io.grpc:grpc-bom,grpc=1.74.0 -com.google.auth:google.google-auth-library-bom,google.auth=1.37.1 +com.google.auth:google-auth-library-bom,google.auth=1.37.1 com.google.http-client:google-http-client,google.http-client=1.47.1 com.google.code.gson:gson,gson=2.13.1 com.google.guava:guava,guava=33.4.8-jre diff --git a/renovate.json b/renovate.json index e16d2dcb2e..805c084b6c 100644 --- a/renovate.json +++ b/renovate.json @@ -9,39 +9,203 @@ "ignorePaths": [ "^library_generation/requirements\\.txt$" ], - "bazel": { - "enabled": false - }, - "cloudbuild": { - "enabled": false - }, - "dockerfile": { - "enabled": false - }, - "gradle": { - "enabled": false - }, - "gradle-wrapper": { - "enabled": false - }, - "maven": { - "enabled": false - }, - "pip_setup": { - "enabled": false - }, - "pip_requirements": { - "enabled": false - }, - "github-actions": { - "enabled": false - }, "customManagers": [ { "customType": "regex", "managerFilePatterns": ["/^dependencies\\.txt$/"], "matchStrings": ["(?.*),(.*)=(?.*)"], "datasourceTemplate": "maven" + }, + { + "customType": "regex", + "fileMatch": [ + "^gax-java/dependencies\\.properties$" + ], + "matchStrings": [ + "version\\.google_java_format=(?.+?)\\n" + ], + "depNameTemplate": "com.google.googlejavaformat:google-java-format", + "datasourceTemplate": "maven" + }, + { + "customType": "regex", + "fileMatch": [ + "^gax-java/dependencies\\.properties$", + "^\\.cloudbuild/library_generation/library_generation.*\\.Dockerfile$" + ], + "matchStrings": [ + "version\\.io_grpc=(?.+?)\\n", + "ARG GRPC_VERSION=[\"']?(?.+?)[\"']?\\s+" + ], + "depNameTemplate": "io.grpc:grpc-core", + "datasourceTemplate": "maven" + }, + { + "customType": "regex", + "fileMatch": [ + "^.kokoro/presubmit/graalvm-native.*.cfg$" + ], + "matchStrings": [ + "value: \"gcr.io/cloud-devrel-kokoro-resources/graalvm:(?.*?)\"", + "value: \"gcr.io/cloud-devrel-kokoro-resources/graalvm17:(?.*?)\"" + ], + "depNameTemplate": "ghcr.io/graalvm/graalvm-ce", + "datasourceTemplate": "docker" + }, + { + "customType": "regex", + "fileMatch": [ + "^.cloudbuild/*" + ], + "matchStrings": [ + " _JAVA_SHARED_CONFIG_VERSION: '(?.+?)'" + ], + "depNameTemplate": "com.google.cloud:google-cloud-shared-config", + "datasourceTemplate": "maven" + }, + { + "customType": "regex", + "fileMatch": [ + "^.cloudbuild/library_generation/library_generation.*\\.Dockerfile$" + ], + "matchStrings": [ + "OWLBOT_CLI_COMMITTISH=(?.*?)\\n" + ], + "currentValueTemplate": "main", + "depNameTemplate": "repo-automation-bots", + "packageNameTemplate": "https://github.com/googleapis/repo-automation-bots", + "datasourceTemplate": "git-refs" + } + ], + "packageRules": [ + { + "matchPackageNames": [ + "com.google.cloud:google-cloud-shared-config" + ], + "registryUrls": [ + "https://repo.maven.apache.org/maven2/", + "https://repo1.maven.org/maven2" + ] + }, + { + "matchUpdateTypes": [ + "major" + ], + "enabled": false, + "matchPackageNames": [ + "*" + ] + }, + { + "enabled": false, + "matchPackageNames": [ + "/^com.google.protobuf:/" + ] + }, + { + "versioning": "docker", + "matchPackageNames": [ + "/^com.google.guava:/" + ], + "enabled": false + }, + { + "semanticCommitType": "deps", + "semanticCommitScope": null, + "matchPackageNames": [ + "*" + ] + }, + { + "semanticCommitType": "build", + "semanticCommitScope": "deps", + "enabled": true, + "matchPackageNames": [ + "/^org.apache.maven/", + "/^org.jacoco:/", + "/^org.codehaus.mojo:/", + "/^org.sonatype.plugins:/", + "/^com.google.cloud:google-cloud-shared-config/" + ] + }, + { + "semanticCommitType": "chore", + "semanticCommitScope": "deps", + "matchPackageNames": [ + "/^{{metadata['repo']['distribution_name']}}/", + "/^com.google.cloud:libraries-bom/", + "/^com.google.cloud.samples:shared-configuration/" + ] + }, + { + "semanticCommitType": "test", + "semanticCommitScope": "deps", + "matchPackageNames": [ + "/^junit:junit/", + "/^com.google.truth:truth/", + "/^org.mockito:mockito-core/", + "/^org.objenesis:objenesis/", + "/^com.google.cloud:google-cloud-conformance-tests/" + ] + }, + { + "ignoreUnstable": false, + "matchPackageNames": [ + "/^com.google.cloud:google-cloud-/" + ] + }, + { + "groupName": "jackson dependencies", + "matchPackageNames": [ + "/^com.fasterxml.jackson.core/" + ] + }, + { + "groupName": "gRPC dependencies", + "matchPackageNames": [ + "/^io.grpc/" + ], + "enabled": false + }, + { + "groupName": "Google Auth Library dependencies", + "matchPackageNames": [ + "/^com.google.auth/" + ] + }, + { + "groupName": "Google API dependencies", + "matchPackageNames": [ + "/com.google.api.grpc:grpc-google-common-protos/", + "/com.google.api.grpc:grpc-google-iam-v1/", + "/com.google.api.grpc:proto-google-common-protos/", + "/com.google.api.grpc:proto-google-iam-v1/", + "/com.google.api:api-common/" + ] + }, + { + "groupName": "Google HTTP Client dependencies", + "matchPackageNames": [ + "/^com.google.http-client/" + ] + }, + { + "groupName": "OpenCensus dependencies", + "matchPackageNames": [ + "/^io.opencensus/" + ] + }, + { + "groupName": "Netty dependencies", + "matchPackageNames": [ + "/^io.netty/" + ] + }, + { + "groupName": "Error Prone dependencies", + "matchPackageNames": [ + "/^com.google.errorprone/" + ] } ] } From 40d3ffe787e87ad4fe5622eb3869cd08e43c436e Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 15:01:26 -0400 Subject: [PATCH 15/16] chore: Update format --- .github/scripts/test_dependency_compatibility.sh | 6 +++--- dependencies.txt | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index 90c90e796c..5fe3c1e420 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -65,9 +65,9 @@ if [ -z "${dependency_list}" ]; then continue fi # Format from `dependencies.txt`: {GroupID}:{ArtifactID},{PropertyName}={Version} - version=$(echo "${line}" | cut -d'=' -f2) - dependency_and_group_artifact=$(echo "${line}" | cut -d'=' -f1) - dependency=$(echo "${dependency_and_group_artifact}" | cut -d',' -f2) + propertyVersion=$(echo "${line}" | cut -d',' -f2) + dependency=$(echo "${propertyVersion}" | cut -d'=' -f1) + version=$(echo "${propertyVersion}" | cut -d'=' -f2) MAVEN_COMMAND+=" -D${dependency}.version=${version}" done < "${UPPER_BOUND_DEPENDENCY_FILE}" else # This else block means that a list of dependencies was inputted diff --git a/dependencies.txt b/dependencies.txt index 9cc580e6ec..6c44c2eb4f 100644 --- a/dependencies.txt +++ b/dependencies.txt @@ -1,8 +1,8 @@ # This file contains a list of dependencies and their versions to be tested for compatibility. # The format is `{GroupID}:{ArtifactID},{PropertyName}={Version}`. The GAV coordinates -# (specifically the GroupID and ArtifactID are parsed by renovate to find the artifact from Maven -# Central. Version stores the currently known upper bound. MavenPropertyName corresponds to the -# Maven property value in the pom.xml (it is not a 1:1 mapping to the GAV). +# (specifically the GroupID and ArtifactID) are parsed by renovate to find the artifact from Maven +# Central. Version stores the currently known upper bound. PropertyName corresponds to the Maven +# property value in the pom.xml (it is NOT a 1:1 mapping to the GAV). # "1P" refers to First-Party dependencies (owned by Google). # "3P" refers to Third-Party dependencies. From 64e5ccfd11b917616949e6154fc0bf9caee02f28 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 7 Oct 2025 15:02:39 -0400 Subject: [PATCH 16/16] chore: Fix old format text --- .github/scripts/test_dependency_compatibility.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/scripts/test_dependency_compatibility.sh b/.github/scripts/test_dependency_compatibility.sh index 5fe3c1e420..9b07efd1ce 100755 --- a/.github/scripts/test_dependency_compatibility.sh +++ b/.github/scripts/test_dependency_compatibility.sh @@ -9,7 +9,7 @@ # upper-bounds dependency file at the root of the repo. # There are two potential inputs to the script: # 1. -f {file}: Custom file/path for the upper-bound dependencies to test -# 2. -l {deps_list}: Comma-separated list of dependencies to test (e.g. protobuf:4.31.0,guava:33.4.8-jre) +# 2. -l {deps_list}: Comma-separated list of dependencies to test (e.g. protobuf=4.31.0,guava=33.4.8-jre) # Note: Do not include the `-D` prefix or `.version` suffix. Those values will be appended when generating # the maven command. # @@ -25,7 +25,7 @@ set -ex function print_help() { echo "Unexpected input argument for this script." echo "Use -f {file} for the directory of the upper-bound dependencies file." - echo "Use -l {deps_list} for a comma-separated list of dependencies to test (Format: dep1:1.0,dep2:2.0)" + echo "Use -l {deps_list} for a comma-separated list of dependencies to test (Format: dep1=1.0,dep2=2.0)" } # Default to the upper bounds file in the root of the repo