From f53fd52d7b26e88d38a74d2c8a1216a06ae32894 Mon Sep 17 00:00:00 2001 From: Elliotte Rusty Harold Date: Mon, 25 Apr 2022 20:49:58 +0000 Subject: [PATCH] Add Kokoro config for JDK 17 (#9845) * add config for OpenJDK11 * update paths * add JDK17 build --- .../dockerfile/test/java_stretch/Dockerfile | 1 + kokoro/linux/java_jdk17/build.sh | 19 +++++++++++++++++++ kokoro/linux/java_jdk17/continuous.cfg | 11 +++++++++++ kokoro/linux/java_jdk17/presubmit.cfg | 12 ++++++++++++ 4 files changed, 43 insertions(+) create mode 100755 kokoro/linux/java_jdk17/build.sh create mode 100644 kokoro/linux/java_jdk17/continuous.cfg create mode 100644 kokoro/linux/java_jdk17/presubmit.cfg diff --git a/kokoro/linux/dockerfile/test/java_stretch/Dockerfile b/kokoro/linux/dockerfile/test/java_stretch/Dockerfile index 8eeb6a2d1c..0716927637 100644 --- a/kokoro/linux/dockerfile/test/java_stretch/Dockerfile +++ b/kokoro/linux/dockerfile/test/java_stretch/Dockerfile @@ -28,6 +28,7 @@ RUN apt-get update && apt-get install -y \ # Java dependencies maven \ openjdk-11-jdk \ + openjdk-17-jdk \ # Required for the gtest build. python2 \ # Python dependencies diff --git a/kokoro/linux/java_jdk17/build.sh b/kokoro/linux/java_jdk17/build.sh new file mode 100755 index 0000000000..9d0ea2b5ca --- /dev/null +++ b/kokoro/linux/java_jdk17/build.sh @@ -0,0 +1,19 @@ +#!/bin/bash +# +# This is the top-level script we give to Kokoro as the entry point for +# running the "pull request" project: +# +# This script selects a specific Dockerfile (for building a Docker image) and +# a script to run inside that image. Then we delegate to the general +# build_and_run_docker.sh script. + +# Change to repo root +cd $(dirname $0)/../../.. + +export DOCKERHUB_ORGANIZATION=protobuftesting +# The image of the Dockerfile sha1 is fetched from the organization +export DOCKERFILE_DIR=kokoro/linux/dockerfile/test/java_stretch +export DOCKER_RUN_SCRIPT=kokoro/linux/pull_request_in_docker.sh +export OUTPUT_DIR=testoutput +export TEST_SET="java_jdk17" +./kokoro/linux/build_and_run_docker.sh diff --git a/kokoro/linux/java_jdk17/continuous.cfg b/kokoro/linux/java_jdk17/continuous.cfg new file mode 100644 index 0000000000..6bac25c128 --- /dev/null +++ b/kokoro/linux/java_jdk17/continuous.cfg @@ -0,0 +1,11 @@ +# Config file for running tests in Kokoro + +# Location of the build script in repository +build_file: "protobuf/kokoro/linux/java_jdk17/build.sh" +timeout_mins: 60 + +action { + define_artifacts { + regex: "**/sponge_log.xml" + } +} diff --git a/kokoro/linux/java_jdk17/presubmit.cfg b/kokoro/linux/java_jdk17/presubmit.cfg new file mode 100644 index 0000000000..ee80517904 --- /dev/null +++ b/kokoro/linux/java_jdk17/presubmit.cfg @@ -0,0 +1,12 @@ +# Config file for running Linkage Monitor in Kokoro +# https://github.com/GoogleCloudPlatform/cloud-opensource-java/tree/master/linkage-monitor + +# Location of the build script in repository +build_file: "protobuf/kokoro/linux/java_jdk17/build.sh" +timeout_mins: 60 + +action { + define_artifacts { + regex: "**/sponge_log.xml" + } +}