Increase test count

This commit is contained in:
Antonio Andelic 2022-11-07 09:50:39 +00:00
parent 8e1a4bcf9a
commit 7467490861
4 changed files with 36 additions and 33 deletions

View File

@ -10,37 +10,40 @@ on: # yamllint disable-line rule:truthy
workflow_dispatch: workflow_dispatch:
workflow_call: workflow_call:
jobs: jobs:
#KeeperJepsenRelease: KeeperJepsenRelease:
# runs-on: [self-hosted, style-checker] runs-on: [self-hosted, style-checker]
# steps: steps:
# - name: Set envs - name: Set envs
# run: | run: |
# cat >> "$GITHUB_ENV" << 'EOF' cat >> "$GITHUB_ENV" << 'EOF'
# TEMP_PATH=${{runner.temp}}/keeper_jepsen TEMP_PATH=${{runner.temp}}/keeper_jepsen
# REPO_COPY=${{runner.temp}}/keeper_jepsen/ClickHouse REPO_COPY=${{runner.temp}}/keeper_jepsen/ClickHouse
# EOF EOF
# - name: Clear repository - name: Clear repository
# run: | run: |
# sudo rm -fr "$GITHUB_WORKSPACE" && mkdir "$GITHUB_WORKSPACE" sudo rm -fr "$GITHUB_WORKSPACE" && mkdir "$GITHUB_WORKSPACE"
# - name: Check out repository code - name: Check out repository code
# uses: actions/checkout@v2 uses: actions/checkout@v2
# with: with:
# fetch-depth: 0 fetch-depth: 0
# - name: Jepsen Test - name: Jepsen Test
# run: | run: |
# sudo rm -fr "$TEMP_PATH" sudo rm -fr "$TEMP_PATH"
# mkdir -p "$TEMP_PATH" mkdir -p "$TEMP_PATH"
# cp -r "$GITHUB_WORKSPACE" "$TEMP_PATH" cp -r "$GITHUB_WORKSPACE" "$TEMP_PATH"
# cd "$REPO_COPY/tests/ci" docker build -f "$REPO_COPY/docker/test/keeper-jepsen/Dockerfile" -t clickhouse/keeper-jepsen-test "$REPO_COPY/docker/test/keeper-jepsen"
# python3 jepsen_check.py keeper cd "$REPO_COPY/tests/ci"
# - name: Cleanup python3 jepsen_check.py keeper
# if: always() - name: Cleanup
# run: | if: always()
# docker ps --quiet | xargs --no-run-if-empty docker kill ||: run: |
# docker ps --all --quiet | xargs --no-run-if-empty docker rm -f ||: docker ps --quiet | xargs --no-run-if-empty docker kill ||:
# sudo rm -fr "$TEMP_PATH" docker ps --all --quiet | xargs --no-run-if-empty docker rm -f ||:
sudo rm -fr "$TEMP_PATH"
ServerJepsenRelease: ServerJepsenRelease:
runs-on: [self-hosted, style-checker] runs-on: [self-hosted, style-checker]
if: ${{ always() }}
needs: [KeeperJepsenRelease]
steps: steps:
- name: Set envs - name: Set envs
run: | run: |

View File

@ -12,7 +12,7 @@ ENV SHA_TO_TEST=""
ENV NODES_USERNAME="root" ENV NODES_USERNAME="root"
ENV NODES_PASSWORD="" ENV NODES_PASSWORD=""
ENV TESTS_TO_RUN="1" ENV TESTS_TO_RUN="8"
ENV TIME_LIMIT="30" ENV TIME_LIMIT="30"
ENV KEEPER_NODE="" ENV KEEPER_NODE=""

View File

@ -22,12 +22,12 @@
(util/timeout 30000 (util/timeout 30000
(throw (RuntimeException. (throw (RuntimeException.
(str "Connection to " node " timed out"))) (str "Connection to " node " timed out")))
;(util/retry 0.1 (util/retry 0.1
(let [spec (db-spec node) (let [spec (db-spec node)
connection (j/get-connection spec) connection (j/get-connection spec)
added-connection (j/add-connection spec connection)] added-connection (j/add-connection spec connection)]
(assert added-connection) (assert added-connection)
added-connection))) added-connection))))
(defn close-connection (defn close-connection
"Close connection" "Close connection"

View File

@ -11,7 +11,7 @@
(let [c (chc/open-connection node)] (let [c (chc/open-connection node)]
(jdbc/query c "SELECT 1") (jdbc/query c "SELECT 1")
(chc/close-connection c)) (chc/close-connection c))
(catch Exception e (do (info e) false)))) (catch Exception e false)))
(defn start-clickhouse! (defn start-clickhouse!
[node test] [node test]