From 66878c365fa50d54a9f1acefe2c9ff7f45335510 Mon Sep 17 00:00:00 2001 From: Neenu Shaji Date: Thu, 21 Oct 2021 12:49:39 -0400 Subject: [PATCH] chore: fix owlbot.py filename typo (#1675) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * chore: fix owlbot.py filename typo * 🦉 Updates from OwlBot See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * chore: update owlbot image * 🦉 Updates from OwlBot See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * chore: add dependencies.sh script for java17 check Co-authored-by: Owl Bot --- .github/.OwlBot.lock.yaml | 2 +- .github/workflows/ci.yaml | 19 ++++++++++------ .kokoro/build.sh | 5 +++++ .kokoro/dependencies.sh | 23 ++++++++++++++++++- .kokoro/presubmit/graalvm-native.cfg | 33 ++++++++++++++++++++++++++++ README.md | 8 +++---- owlbot.py.py => owlbot.py | 0 7 files changed, 77 insertions(+), 13 deletions(-) create mode 100644 .kokoro/presubmit/graalvm-native.cfg rename owlbot.py.py => owlbot.py (100%) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 942f78aec..859cc6b7a 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest - digest: sha256:b328758e5113c392d3eccad613c2b18097eaebcb4d8bf77fab0326a6cad90bc7 \ No newline at end of file + digest: sha256:d4b2141d65566523dfd523f63c6e6899ab1281463bce182a9f600e74b0511875 \ No newline at end of file diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3932a70d4..2425d7234 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -9,14 +9,15 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - java: [8, 11] + java: [8, 11, 17] steps: - uses: actions/checkout@v2 - uses: stCarolas/setup-maven@v4 with: maven-version: 3.8.1 - - uses: actions/setup-java@v1 + - uses: actions/setup-java@v2 with: + distribution: zulu java-version: ${{matrix.java}} - run: java -version - run: .kokoro/build.sh @@ -29,8 +30,9 @@ jobs: - uses: stCarolas/setup-maven@v4 with: maven-version: 3.8.1 - - uses: actions/setup-java@v1 + - uses: actions/setup-java@v2 with: + distribution: zulu java-version: 8 - run: java -version - run: .kokoro/build.bat @@ -40,14 +42,15 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - java: [8, 11] + java: [8, 11, 17] steps: - uses: actions/checkout@v2 - uses: stCarolas/setup-maven@v4 with: maven-version: 3.8.1 - - uses: actions/setup-java@v1 + - uses: actions/setup-java@v2 with: + distribution: zulu java-version: ${{matrix.java}} - run: java -version - run: .kokoro/dependencies.sh @@ -58,8 +61,9 @@ jobs: - uses: stCarolas/setup-maven@v4 with: maven-version: 3.8.1 - - uses: actions/setup-java@v1 + - uses: actions/setup-java@v2 with: + distribution: zulu java-version: 8 - run: java -version - run: .kokoro/build.sh @@ -72,8 +76,9 @@ jobs: - uses: stCarolas/setup-maven@v4 with: maven-version: 3.8.1 - - uses: actions/setup-java@v1 + - uses: actions/setup-java@v2 with: + distribution: zulu java-version: 8 - run: java -version - run: .kokoro/build.sh diff --git a/.kokoro/build.sh b/.kokoro/build.sh index 2d4c91705..5454c3fc5 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -69,6 +69,11 @@ integration) verify RETURN_CODE=$? ;; +graalvm) + # Run Unit and Integration Tests with Native Image + mvn test -Pnative -Penable-integration-tests + RETURN_CODE=$? + ;; samples) SAMPLES_DIR=samples # only run ITs in snapshot/ on presubmit PRs. run ITs in all 3 samples/ subdirectories otherwise. diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh index 12f1088d8..78fed6d6e 100755 --- a/.kokoro/dependencies.sh +++ b/.kokoro/dependencies.sh @@ -27,7 +27,28 @@ source ${scriptDir}/common.sh java -version echo $JOB_TYPE -export MAVEN_OPTS="-Xmx1024m -XX:MaxPermSize=128m" +function determineMavenOpts() { + local javaVersion=$( + # filter down to the version line, then pull out the version between quotes, + # then trim the version number down to its minimal number (removing any + # update or suffix number). + java -version 2>&1 | grep "version" \ + | sed -E 's/^.*"(.*?)".*$/\1/g' \ + | sed -E 's/^(1\.[0-9]\.0).*$/\1/g' + ) + + case $javaVersion in + "17") + # MaxPermSize is no longer supported as of jdk 17 + echo -n "-Xmx1024m" + ;; + *) + echo -n "-Xmx1024m -XX:MaxPermSize=128m" + ;; + esac +} + +export MAVEN_OPTS=$(determineMavenOpts) # this should run maven enforcer retry_with_backoff 3 10 \ diff --git a/.kokoro/presubmit/graalvm-native.cfg b/.kokoro/presubmit/graalvm-native.cfg new file mode 100644 index 000000000..4c7225ec9 --- /dev/null +++ b/.kokoro/presubmit/graalvm-native.cfg @@ -0,0 +1,33 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/graalvm" +} + +env_vars: { + key: "JOB_TYPE" + value: "graalvm" +} + +# TODO: remove this after we've migrated all tests and scripts +env_vars: { + key: "GCLOUD_PROJECT" + value: "gcloud-devel" +} + +env_vars: { + key: "GOOGLE_CLOUD_PROJECT" + value: "gcloud-devel" +} + +env_vars: { + key: "GOOGLE_APPLICATION_CREDENTIALS" + value: "secret_manager/java-it-service-account" +} + +env_vars: { + key: "SECRET_MANAGER_KEYS" + value: "java-it-service-account" +} diff --git a/README.md b/README.md index b428027cc..aee18110e 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ If you are using Maven without BOM, add this to your dependencies: com.google.cloud google-cloud-bigquery - 2.1.7 + 2.1.13 ``` @@ -51,20 +51,20 @@ If you are using Maven without BOM, add this to your dependencies: If you are using Gradle 5.x or later, add this to your dependencies ```Groovy -implementation platform('com.google.cloud:libraries-bom:23.0.0') +implementation platform('com.google.cloud:libraries-bom:23.1.0') implementation 'com.google.cloud:google-cloud-bigquery' ``` If you are using Gradle without BOM, add this to your dependencies ```Groovy -implementation 'com.google.cloud:google-cloud-bigquery:2.1.7' +implementation 'com.google.cloud:google-cloud-bigquery:2.3.2' ``` If you are using SBT, add this to your dependencies ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigquery" % "2.1.7" +libraryDependencies += "com.google.cloud" % "google-cloud-bigquery" % "2.3.2" ``` ## Authentication diff --git a/owlbot.py.py b/owlbot.py similarity index 100% rename from owlbot.py.py rename to owlbot.py