diff --git a/.github/workflows/ci-pull-request-title.yaml b/.github/workflows/ci-pull-request-title.yaml index 2e58da6656..db323f1b7f 100644 --- a/.github/workflows/ci-pull-request-title.yaml +++ b/.github/workflows/ci-pull-request-title.yaml @@ -10,6 +10,6 @@ jobs: main: runs-on: ubuntu-latest steps: - - uses: amannn/action-semantic-pull-request@v2.2.0 + - uses: amannn/action-semantic-pull-request@v3.1.0 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/ci-pull-request.yaml b/.github/workflows/ci-pull-request.yaml new file mode 100644 index 0000000000..ee3c3fb76f --- /dev/null +++ b/.github/workflows/ci-pull-request.yaml @@ -0,0 +1,67 @@ +# 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: pull_request + +on: + # run on each pull request + pull_request: + types: [ synchronize, reopened, labeled ] + branches: + - master + - 'v[0-9]+.*' # release branch + - ci-test # testing branch for github action + paths: + - 'rdsn/**' + - 'src/**' + - '.github/workflows/ci-pull-request.yml' + push: + paths: + - '.github/workflows/ci-pull-request.yml' + # for manually triggering workflow + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + lint: + name: Lint + runs-on: ubuntu-latest + container: + image: apachepegasus/clang-format-3.9 + defaults: + run: + working-directory: /root/incubator-pegasus + steps: + - name: Clone Apache Pegasus Source + working-directory: /root + run: | + git clone --recursive --depth=1 https://github.com/apache/incubator-pegasus.git + - name: clang-format + run: ./rdsn/scripts/linux/run-clang-format.py --clang-format-executable clang-format-3.9 -e ./src/shell/linenoise -e ./src/shell/sds -e ./rdsn -r ./src + + test: + name: Test + needs: lint + runs-on: ubuntu-latest + container: + image: apachepegasus/ci-env + defaults: + run: + working-directory: /root/incubator-pegasus + steps: + - name: Clone Apache Pegasus Source + working-directory: /root + run: | + git clone --recursive --depth=1 https://github.com/apache/incubator-pegasus.git + - name: Unpack prebuilt third-parties + run: unzip /root/pegasus-thirdparty-output.zip -d ./rdsn/thirdparty + - name: Compilation + run: ./run.sh build -c --skip_thirdparty + - name: Unit Testing + run: ./run.sh test --on_travis diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 209bd46674..0000000000 --- a/.travis.yml +++ /dev/null @@ -1,41 +0,0 @@ -sudo: required -dist: bionic - -language: cpp - -compiler: - - gcc - -addons: - apt: - packages: - - libsnappy-dev - - liblz4-dev - - clang-format-3.9 - - libaio-dev - - libzstd-dev - -cache: - - ccache - - apt - -before_install: - - python --version - - pip install -U cmake # use the latest version of cmake - -before_script: - - cd rdsn/thirdparty - - wget https://github.com/XiaoMi/pegasus-common/releases/download/deps/pegasus-thirdparty-prebuild-bionic.zip - - unzip pegasus-thirdparty-prebuild-bionic.zip - - rm -f pegasus-thirdparty-prebuild-bionic.zip - - cd ../.. - - ulimit -c unlimited -S - -script: - - ./scripts/travis.sh - -after_script: - - ./run.sh stop_zk - -notifications: - email: false diff --git a/rdsn b/rdsn index 7404376b45..d8cbbe5985 160000 --- a/rdsn +++ b/rdsn @@ -1 +1 @@ -Subproject commit 7404376b45cde468df2435cab3f6913fe7e2dd40 +Subproject commit d8cbbe59854fd382d10954349f24c058ffa1b107