This is an automated email from the ASF dual-hosted git repository.
wangdan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-pegasus.git
The following commit(s) were added to refs/heads/master by this push:
new b6123e649 chore(workflow): fix clang-format action not work bug (#1044)
b6123e649 is described below
commit b6123e64905ce0234310889f8429266bff83435f
Author: Yingchun Lai <[email protected]>
AuthorDate: Mon Jul 11 14:27:57 2022 +0800
chore(workflow): fix clang-format action not work bug (#1044)
---
.github/workflows/check_license_header.yaml | 43 ---------
.../{test_rdsn.yaml => lint_and_test_cpp.yaml} | 101 ++++++++++++++++-----
.github/workflows/lint_and_test_pegasus.yaml | 85 -----------------
.../lint_and_test_pegasus_always_pass.yaml | 54 -----------
.github/workflows/standardization_lint.yaml | 24 ++++-
.github/workflows/test_rdsn_always_pass.yaml | 70 --------------
6 files changed, 98 insertions(+), 279 deletions(-)
diff --git a/.github/workflows/check_license_header.yaml
b/.github/workflows/check_license_header.yaml
deleted file mode 100644
index 39ef9ed79..000000000
--- a/.github/workflows/check_license_header.yaml
+++ /dev/null
@@ -1,43 +0,0 @@
-# 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.
----
-name: License Check
-on:
- pull_request:
- push:
- branches:
- - master
- - 'v[0-9]+.*' # release branch
- - ci-test # testing branch for github action
- - '*dev' # developing branch
-
-jobs:
- license-check:
- name: "License Check"
- runs-on: ubuntu-latest
- steps:
- - name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
- uses: actions/checkout@v2
- - name: Check License Header
- uses: apache/[email protected]
- env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # needed only when you
want License-Eye to comment on the pull request.
- with:
- # Optional: set the log level. The default value is `info`.
- # log: debug
- # Optional: set the config file. The default value is
`.licenserc.yaml`.
- config: .licenserc.yaml
diff --git a/.github/workflows/test_rdsn.yaml
b/.github/workflows/lint_and_test_cpp.yaml
similarity index 74%
rename from .github/workflows/test_rdsn.yaml
rename to .github/workflows/lint_and_test_cpp.yaml
index b6c991554..20f0e3ef7 100644
--- a/.github/workflows/test_rdsn.yaml
+++ b/.github/workflows/lint_and_test_cpp.yaml
@@ -21,26 +21,17 @@
# it's recommended to create a PR against the ci-test branch to test if it
works
# as expected.
-name: rdsn Unit Test
+name: Lint and Unit Test for Cpp
on:
# run on each pull request
pull_request:
types: [ synchronize, opened, reopened ]
- paths:
- - .github/workflows/test_rdsn.yaml
- - rdsn/CMakeLists.txt
- - rdsn/bin/**
- - rdsn/compile_thrift.py
- - rdsn/include/**
- - rdsn/scripts/**
- - rdsn/src/**
- - rdsn/thirdparty/**
branches:
- master
- 'v[0-9]+.*' # release branch
- ci-test # testing branch for github action
- - '*dev' # developing branch
+ - '*dev'
# for manually triggering workflow
workflow_dispatch:
@@ -50,8 +41,22 @@ defaults:
shell: bash
jobs:
- test:
- name: Test
+ cpp_clang_format_linter:
+ name: Lint Cpp code
+ runs-on: ubuntu-latest
+ container:
+ image: apache/pegasus:clang-format-3.9
+ steps:
+ - uses: actions/checkout@v2
+ with:
+ fetch-depth: 1
+ submodules: true
+ - name: clang-format
+ run: ./scripts/run-clang-format.py --clang-format-executable
clang-format-3.9 -e ./src/shell/linenoise -e ./src/shell/sds -e
./rdsn/thirdparty -r .
+
+ test_rdsn_Release:
+ name: Test rdsn with Release
+ needs: cpp_clang_format_linter
runs-on: ubuntu-latest
container:
image: apache/pegasus:thirdparties-bin-ubuntu1804
@@ -69,6 +74,8 @@ jobs:
id: changes
with:
filters: |
+ rdsn:
+ - 'rdsn/**'
thirdparty:
- 'rdsn/thirdparty/**'
- name: Unpack prebuilt third-parties
@@ -83,13 +90,15 @@ jobs:
cmake -DCMAKE_BUILD_TYPE=Release -B build/
cmake --build build/ -j $(($(nproc)/2+1))
- name: Compilation and Unit Testing
+ if: steps.changes.outputs.rdsn == 'true'
run: |
- export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
+ export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
ulimit -s unlimited
./run.sh build -c --rdsn --test --skip_thirdparty -j
$(($(nproc)/2+1))
- test-with-sanitizer-address:
- name: Test With Sanitizer Address
+ test_rdsn_ASAN:
+ name: Test rdsn with ASAN
+ needs: cpp_clang_format_linter
runs-on: ubuntu-latest
container:
image: apache/pegasus:thirdparties-bin-ubuntu1804
@@ -107,6 +116,8 @@ jobs:
id: changes
with:
filters: |
+ rdsn:
+ - 'rdsn/**'
thirdparty:
- 'rdsn/thirdparty/**'
- name: Unpack prebuilt third-parties
@@ -121,13 +132,15 @@ jobs:
cmake -DCMAKE_BUILD_TYPE=Release -B build/
cmake --build build/ -j $(($(nproc)/2+1))
- name: Compilation and Unit Testing
+ if: steps.changes.outputs.rdsn == 'true'
run: |
- export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
+ export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
ulimit -s unlimited
./run.sh build -c --rdsn --test --sanitizer address
--skip_thirdparty --disable_gperf -j $(($(nproc)/2+1))
- test-with-sanitizer-leak:
- name: Test With Sanitizer Leak
+ test_rdsn_LSAN:
+ name: Test rdsn with LSAN
+ needs: cpp_clang_format_linter
runs-on: ubuntu-latest
container:
image: apache/pegasus:thirdparties-bin-ubuntu1804
@@ -145,6 +158,8 @@ jobs:
id: changes
with:
filters: |
+ rdsn:
+ - 'rdsn/**'
thirdparty:
- 'rdsn/thirdparty/**'
- name: Unpack prebuilt third-parties
@@ -159,13 +174,15 @@ jobs:
cmake -DCMAKE_BUILD_TYPE=Release -B build/
cmake --build build/ -j $(($(nproc)/2+1))
- name: Compilation and Unit Testing
+ if: steps.changes.outputs.rdsn == 'true'
run: |
- export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
+ export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
ulimit -s unlimited
./run.sh build -c --rdsn --test --sanitizer leak --skip_thirdparty
--disable_gperf -j $(($(nproc)/2+1))
- test-with-sanitizer-undefined:
- name: Test With Sanitizer Undefined
+ test_rdsn_UBSAN:
+ name: Test rdsn with UBSAN
+ needs: cpp_clang_format_linter
runs-on: ubuntu-latest
container:
image: apache/pegasus:thirdparties-bin-ubuntu1804
@@ -183,6 +200,8 @@ jobs:
id: changes
with:
filters: |
+ rdsn:
+ - 'rdsn/**'
thirdparty:
- 'rdsn/thirdparty/**'
- name: Unpack prebuilt third-parties
@@ -197,7 +216,43 @@ jobs:
cmake -DCMAKE_BUILD_TYPE=Release -B build/
cmake --build build/ -j $(($(nproc)/2+1))
- name: Compilation and Unit Testing
+ if: steps.changes.outputs.rdsn == 'true'
run: |
- export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
+ export
LD_LIBRARY_PATH=`pwd`/thirdparty/output/lib:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server
ulimit -s unlimited
./run.sh build -c --rdsn --test --sanitizer undefined
--skip_thirdparty --disable_gperf -j $(($(nproc)/2+1))
+
+ test_pegasus:
+ name: Test Pegasus
+ needs: cpp_clang_format_linter
+ runs-on: ubuntu-latest
+ container:
+ image: apache/pegasus:thirdparties-bin-ubuntu1804
+ defaults:
+ run:
+ shell: bash
+ steps:
+ - uses: actions/checkout@v2
+ - uses: dorny/paths-filter@v2
+ id: changes
+ with:
+ filters: |
+ pegasus:
+ - 'src/**'
+ - name: Unpack prebuilt third-parties
+ if: steps.changes.outputs.pegasus == 'true'
+ run: unzip /root/thirdparties-bin.zip -d ./rdsn/thirdparty
+ - name: Compilation
+ if: steps.changes.outputs.pegasus == 'true'
+ run: ./run.sh build -c -j $(($(nproc)/2+1))
+ - name: Packaging Server
+ if: steps.changes.outputs.pegasus == 'true'
+ run: ./run.sh pack_server
+ - name: Packaging Tools
+ if: steps.changes.outputs.pegasus == 'true'
+ run: ./run.sh pack_tools
+ - name: Unit Testing
+ if: steps.changes.outputs.pegasus == 'true'
+ run: |
+ source ./scripts/config_hdfs.sh
+ ./run.sh test --on_travis
diff --git a/.github/workflows/lint_and_test_pegasus.yaml
b/.github/workflows/lint_and_test_pegasus.yaml
deleted file mode 100644
index 4f904de4e..000000000
--- a/.github/workflows/lint_and_test_pegasus.yaml
+++ /dev/null
@@ -1,85 +0,0 @@
-# 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.
----
-# Developer Notes:
-#
-# This config is for github actions. Before merging your changes of this file,
-# it's recommended to create a PR against the ci-test branch to test if it
works
-# as expected.
-
-name: Pegasus cpp Lint and Unit Test
-
-on:
- # run on each pull request
- pull_request:
- types: [ synchronize, opened, reopened ]
- paths:
- - src/**
- - rdsn
- - run.sh
- branches:
- - master
- - 'v[0-9]+.*' # release branch
- - ci-test # testing branch for github action
- - '*dev'
-
- # for manually triggering workflow
- workflow_dispatch:
-
-defaults:
- run:
- shell: bash
-
-jobs:
- lint:
- name: Lint
- runs-on: ubuntu-latest
- container:
- image: apache/pegasus:clang-format-3.9
- steps:
- - uses: actions/checkout@v2
- with:
- fetch-depth: 1
- submodules: true
- - name: clang-format
- run: ./scripts/run-clang-format.py --clang-format-executable
clang-format-3.9 -e ./src/shell/linenoise -e ./src/shell/sds -e
./rdsn/thirdparty -r .
-
- test:
- name: Test
- needs: lint
- runs-on: ubuntu-latest
- container:
- image: apache/pegasus:thirdparties-bin-ubuntu1804
- defaults:
- run:
- shell: bash
- steps:
- - uses: actions/checkout@v2
- with:
- submodules: recursive
- - name: Unpack prebuilt third-parties
- run: unzip /root/thirdparties-bin.zip -d ./rdsn/thirdparty
- - name: Compilation
- run: ./run.sh build -c -j $(($(nproc)/2+1))
- - name: Packaging Server
- run: ./run.sh pack_server
- - name: Packaging Tools
- run: ./run.sh pack_tools
- - name: Unit Testing
- run: |
- source ./scripts/config_hdfs.sh
- ./run.sh test --on_travis
diff --git a/.github/workflows/lint_and_test_pegasus_always_pass.yaml
b/.github/workflows/lint_and_test_pegasus_always_pass.yaml
deleted file mode 100644
index e68e40228..000000000
--- a/.github/workflows/lint_and_test_pegasus_always_pass.yaml
+++ /dev/null
@@ -1,54 +0,0 @@
-# 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.
----
-# There are 'paths' filters for lint_and_test_pegasus.yaml,
-# it can be skipped, but lead CI pending, we add this
-# 'always pass' action to resolve it, see more details:
-#
https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks
-
-name: Pegasus cpp Lint and Unit Test
-
-on:
- # run on each pull request
- pull_request:
- types: [ synchronize, opened, reopened ]
- paths-ignore:
- - src/**
- - rdsn
- - run.sh
- branches:
- - master
- - 'v[0-9]+.*' # release branch
- - ci-test # testing branch for github action
- - '*dev'
-
- # for manually triggering workflow
- workflow_dispatch:
-
-jobs:
- lint:
- name: Lint
- runs-on: ubuntu-latest
- steps:
- - run: 'echo "No build required" '
-
- test:
- name: Test
- needs: lint
- runs-on: ubuntu-latest
- steps:
- - run: 'echo "No build required" '
diff --git a/.github/workflows/standardization_lint.yaml
b/.github/workflows/standardization_lint.yaml
index 67134743a..5b9e5fc26 100644
--- a/.github/workflows/standardization_lint.yaml
+++ b/.github/workflows/standardization_lint.yaml
@@ -17,16 +17,16 @@
---
name: Standardization Lint
+# on events
on:
# run on each pull request
pull_request:
- types: [ edited, synchronize, opened, reopened ]
+ types: [ synchronize, opened, reopened, edited ]
branches:
- master
- 'v[0-9]+.*' # release branch
- ci-test # testing branch for github action
- - '*dev' # developing branch
-
+ - '*dev'
# for manually triggering workflow
workflow_dispatch:
@@ -66,7 +66,23 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: hadolint/[email protected]
+ - uses: hadolint/[email protected]
with:
recursive: true
ignore:
'DL3033,DL3013,DL3059,SC2086,DL3003,SC2164,DL3008,DL3007,DL3006'
+
+ license_check:
+ name: Check License
+ runs-on: ubuntu-latest
+ steps:
+ - name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
+ uses: actions/checkout@v2
+ - name: Check License Header
+ uses: apache/[email protected]
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # needed only when you
want License-Eye to comment on the pull request.
+ with:
+ # Optional: set the log level. The default value is `info`.
+ # log: debug
+ # Optional: set the config file. The default value is
`.licenserc.yaml`.
+ config: .licenserc.yaml
diff --git a/.github/workflows/test_rdsn_always_pass.yaml
b/.github/workflows/test_rdsn_always_pass.yaml
deleted file mode 100644
index c39c406a6..000000000
--- a/.github/workflows/test_rdsn_always_pass.yaml
+++ /dev/null
@@ -1,70 +0,0 @@
-# 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.
----
-# There are 'paths' filters for .github/workflows/cpp_actions.yaml,
-# it can be skipped, but lead CI pending, we add this
-# 'always pass' action to resolve it, see more details:
-#
https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks
-
-name: rdsn Unit Test
-
-on:
- # run on each pull request
- pull_request:
- types: [ synchronize, opened, reopened ]
- paths-ignore:
- - .github/workflows/cpp_actions.yaml
- - rdsn/CMakeLists.txt
- - rdsn/bin/**
- - rdsn/compile_thrift.py
- - rdsn/include/**
- - rdsn/scripts/**
- - rdsn/src/**
- - rdsn/thirdparty/**
- branches:
- - master
- - 'v[0-9]+.*' # release branch
- - ci-test # testing branch for github action
- - '*dev' # developing branch
-
- # for manually triggering workflow
- workflow_dispatch:
-
-jobs:
- test:
- name: Test
- runs-on: ubuntu-latest
- steps:
- - run: 'echo "No build required" '
-
- test-with-sanitizer-address:
- name: Test With Sanitizer Address
- runs-on: ubuntu-latest
- steps:
- - run: 'echo "No build required" '
-
- test-with-sanitizer-leak:
- name: Test With Sanitizer Leak
- runs-on: ubuntu-latest
- steps:
- - run: 'echo "No build required" '
-
- test-with-sanitizer-undefined:
- name: Test With Sanitizer Undefined
- runs-on: ubuntu-latest
- steps:
- - run: 'echo "No build required" '
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]