From dd30f0bce76b9192eb5e71f8936b30f29fa3c135 Mon Sep 17 00:00:00 2001 From: andoni-guzman Date: Mon, 17 Oct 2022 18:24:02 -0500 Subject: [PATCH] Added tests for aws, aws2, azure, cassandra and cdap, modifty ci.md --- .../workflows/job-precommit-java-io-aws.yml | 54 +++++++++++++++++++ .../workflows/job-precommit-java-io-aws2.yml | 54 +++++++++++++++++++ .../workflows/job-precommit-java-io-azure.yml | 54 +++++++++++++++++++ .../job-precommit-java-io-cassandra.yml | 54 +++++++++++++++++++ .../workflows/job-precommit-java-io-cdap.yml | 54 +++++++++++++++++++ CI.md | 10 ++++ 6 files changed, 280 insertions(+) create mode 100644 .github/workflows/job-precommit-java-io-aws.yml create mode 100644 .github/workflows/job-precommit-java-io-aws2.yml create mode 100644 .github/workflows/job-precommit-java-io-azure.yml create mode 100644 .github/workflows/job-precommit-java-io-cassandra.yml create mode 100644 .github/workflows/job-precommit-java-io-cdap.yml diff --git a/.github/workflows/job-precommit-java-io-aws.yml b/.github/workflows/job-precommit-java-io-aws.yml new file mode 100644 index 000000000000..ed55fc8ec676 --- /dev/null +++ b/.github/workflows/job-precommit-java-io-aws.yml @@ -0,0 +1,54 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Test for Precommit Java IO AWS + +name: Precommit Java IO AWS + +on: + workflow_dispatch: + schedule: + - cron: '0 */6 * * *' + push: + branches: ['master', 'release-*'] + tags: 'v*' + pull_request_target: + branches: ['master', 'release-*'] + tags: 'v*' + paths: ['sdks/java/io/amazon-web-services/**'] +permissions: read-all + +jobs: + run-precommit-java-io-aws: + name: Run Precommit Java IO AWS + runs-on: [self-hosted, ubuntu-20.04] + timeout-minutes: 200 + steps: + - name: Checkout code + uses: actions/checkout@v3 + with: + ref: ${{ github.event.pull_request.head.sha }} + persist-credentials: false + - name: Setup environment + uses: ./.github/actions/setup-self-hosted-action + with: + requires-py-37: false + requires-py-38: false + requires-py-39: false + requires-go-18: false + - name: SDKs Java IO AWS - :sdks:java:io:amazon-web-services:test + uses: ./.github/actions/gradle-command-self-hosted-action + with: + gradle-command: :sdks:java:io:amazon-web-services:test \ No newline at end of file diff --git a/.github/workflows/job-precommit-java-io-aws2.yml b/.github/workflows/job-precommit-java-io-aws2.yml new file mode 100644 index 000000000000..e91812e64b49 --- /dev/null +++ b/.github/workflows/job-precommit-java-io-aws2.yml @@ -0,0 +1,54 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Test for Precommit Java IO AWS 2 + +name: Precommit Java IO AWS 2 + +on: + workflow_dispatch: + schedule: + - cron: '0 */6 * * *' + push: + branches: ['master', 'release-*'] + tags: 'v*' + pull_request_target: + branches: ['master', 'release-*'] + tags: 'v*' + paths: ['sdks/java/io/amazon-web-services2/**'] +permissions: read-all + +jobs: + run-precommit-java-io-aws2: + name: Run Precommit Java IO AWS 2 + runs-on: [self-hosted, ubuntu-20.04] + timeout-minutes: 200 + steps: + - name: Checkout code + uses: actions/checkout@v3 + with: + ref: ${{ github.event.pull_request.head.sha }} + persist-credentials: false + - name: Setup environment + uses: ./.github/actions/setup-self-hosted-action + with: + requires-py-37: false + requires-py-38: false + requires-py-39: false + requires-go-18: false + - name: SDKs Java IO AWS 2 - :sdks:java:io:amazon-web-services2:test + uses: ./.github/actions/gradle-command-self-hosted-action + with: + gradle-command: :sdks:java:io:amazon-web-services2:test \ No newline at end of file diff --git a/.github/workflows/job-precommit-java-io-azure.yml b/.github/workflows/job-precommit-java-io-azure.yml new file mode 100644 index 000000000000..846cad3fbd6d --- /dev/null +++ b/.github/workflows/job-precommit-java-io-azure.yml @@ -0,0 +1,54 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Test for Precommit Java IO Azure + +name: Precommit Java IO Azure + +on: + workflow_dispatch: + schedule: + - cron: '0 */6 * * *' + push: + branches: ['master', 'release-*'] + tags: 'v*' + pull_request_target: + branches: ['master', 'release-*'] + tags: 'v*' + paths: ['sdks/java/io/azure/**'] +permissions: read-all + +jobs: + run-precommit-java-io-azure: + name: Run Precommit Java IO Azure + runs-on: [self-hosted, ubuntu-20.04] + timeout-minutes: 200 + steps: + - name: Checkout code + uses: actions/checkout@v3 + with: + ref: ${{ github.event.pull_request.head.sha }} + persist-credentials: false + - name: Setup environment + uses: ./.github/actions/setup-self-hosted-action + with: + requires-py-37: false + requires-py-38: false + requires-py-39: false + requires-go-18: false + - name: SDKs Java IO Azure - :sdks:java:io:azure:test + uses: ./.github/actions/gradle-command-self-hosted-action + with: + gradle-command: :sdks:java:io:azure:test \ No newline at end of file diff --git a/.github/workflows/job-precommit-java-io-cassandra.yml b/.github/workflows/job-precommit-java-io-cassandra.yml new file mode 100644 index 000000000000..13a13df85707 --- /dev/null +++ b/.github/workflows/job-precommit-java-io-cassandra.yml @@ -0,0 +1,54 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Test for Precommit Java IO Cassandra + +name: Precommit Java IO Cassandra + +on: + workflow_dispatch: + schedule: + - cron: '0 */6 * * *' + push: + branches: ['master', 'release-*'] + tags: 'v*' + pull_request_target: + branches: ['master', 'release-*'] + tags: 'v*' + paths: ['sdks/java/io/cassandra/**'] +permissions: read-all + +jobs: + run-precommit-java-io-cassandra: + name: Run Precommit Java IO Cassandra + runs-on: [self-hosted, ubuntu-20.04] + timeout-minutes: 200 + steps: + - name: Checkout code + uses: actions/checkout@v3 + with: + ref: ${{ github.event.pull_request.head.sha }} + persist-credentials: false + - name: Setup environment + uses: ./.github/actions/setup-self-hosted-action + with: + requires-py-37: false + requires-py-38: false + requires-py-39: false + requires-go-18: false + - name: SDKs Java IO Cassandra - :sdks:java:io:cassandra:test + uses: ./.github/actions/gradle-command-self-hosted-action + with: + gradle-command: :sdks:java:io:cassandra:test \ No newline at end of file diff --git a/.github/workflows/job-precommit-java-io-cdap.yml b/.github/workflows/job-precommit-java-io-cdap.yml new file mode 100644 index 000000000000..2a1de8aa0333 --- /dev/null +++ b/.github/workflows/job-precommit-java-io-cdap.yml @@ -0,0 +1,54 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Test for Precommit Java IO CDAP + +name: Precommit Java IO CDAP + +on: + workflow_dispatch: + schedule: + - cron: '0 */6 * * *' + push: + branches: ['master', 'release-*'] + tags: 'v*' + pull_request_target: + branches: ['master', 'release-*'] + tags: 'v*' + paths: ['sdks/java/io/cdap/**'] +permissions: read-all + +jobs: + run-precommit-java-io-cdap: + name: Run Precommit Java IO CDAP + runs-on: [self-hosted, ubuntu-20.04] + timeout-minutes: 200 + steps: + - name: Checkout code + uses: actions/checkout@v3 + with: + ref: ${{ github.event.pull_request.head.sha }} + persist-credentials: false + - name: Setup environment + uses: ./.github/actions/setup-self-hosted-action + with: + requires-py-37: false + requires-py-38: false + requires-py-39: false + requires-go-18: false + - name: SDKs Java IO CDAP - :sdks:java:io:cdap:test + uses: ./.github/actions/gradle-command-self-hosted-action + with: + gradle-command: :sdks:java:io:cdap:test \ No newline at end of file diff --git a/CI.md b/CI.md index ed75a4dd4433..913db20b5212 100644 --- a/CI.md +++ b/CI.md @@ -125,6 +125,16 @@ Service Account shall have following permissions ([IAM roles](https://cloud.goog | Java Wordcount Direct Runner | Runs Java WordCount example with Direct Runner. | Yes | Yes | Yes | - | | Java Wordcount Dataflow | Runs Java WordCount example with DataFlow Runner. | - | Yes | Yes | Yes | +### PreCommit Workflows +| Workflow | Description | Requires GCP Credentials | +|------------------------------------------------------------------------------------------------|-------------------------|---------------------------| +| [job-precommit-placeholder.yml](.github/workflows/job-precommit-placeholder.yml) | Description placeholder | Yes/No | +| [job-precommit-java-io-aws.yml](.github/workflows/job-precommit-java-io-aws.yml) | Run Java IO AWS | No | +| [job-precommit-java-io-aws2.yml](.github/workflows/job-precommit-java-io-hbase.yml) | Run Java IO AWS 2 | No | +| [job-precommit-java-io-azure.yml](.github/workflows/job-precommit-java-io-hcatalog.yml) | Run Java IO Azure | No | +| [job-precommit-java-io-cassandra.yml](.github/workflows/job-precommit-java-io-hdfs.yml) | Run Java IO Cassandra | No | +| [job-precommit-java-io-cdap.yml](.github/workflows/job-precommit-java-io-file-based.yml) | Run Java IO CDAP | No | + ### GitHub Action Tips * If you introduce changes to the workflow it is possible that your changes will not be present in the check run triggered in Pull Request.