From 444da423d5a0e846852a51c80bb7a128b7a50d24 Mon Sep 17 00:00:00 2001 From: Ekaterina Dimitrova Date: Fri, 11 Nov 2022 22:07:12 -0500 Subject: [PATCH] CirleCI: Add large Dtests and J8/J11 Java distributed tests; Fix CQLSHLIB tests config and Python DTests split; CQLSHLIB tests should run with NUM_TOKENS=16 patch by Ekaterina Dimitrova; reviewed by Andres de la Pena for CASSANDRA-18001 --- .circleci/config-2_1.yml | 397 ++++++- .circleci/config-2_1.yml.high_res.patch | 70 +- .circleci/config-2_1.yml.mid_res.patch | 97 +- .circleci/config.yml | 1406 ++++++++++++++++++++++- .circleci/config.yml.HIGHRES | 1406 ++++++++++++++++++++++- .circleci/config.yml.LOWRES | 1406 ++++++++++++++++++++++- .circleci/config.yml.MIDRES | 1406 ++++++++++++++++++++++- .circleci/generate.sh | 16 +- .circleci/readme.md | 4 + pylib/cassandra-cqlsh-tests.sh | 2 +- 10 files changed, 6033 insertions(+), 177 deletions(-) diff --git a/.circleci/config-2_1.yml b/.circleci/config-2_1.yml index 578382e43a..3f83b74094 100644 --- a/.circleci/config-2_1.yml +++ b/.circleci/config-2_1.yml @@ -114,6 +114,15 @@ default_env_vars: &default_env_vars # The number of times that the manually specified Python dtests should be run. REPEATED_DTESTS_COUNT: 500 + # Comma-separated list of Python large dtests that should be repeatedly run, for example: + # REPEATED_LARGE_DTESTS: consistency_test.py + # REPEATED_LARGE_DTESTS: consistency_test.py::TestAvailability + # REPEATED_LARGE_DTESTS: consistency_test.py::TestAvailability::test_network_topology_strategy + # REPEATED_LARGE_DTESTS: consistency_test.py,materialized_views_test.py + REPEATED_LARGE_DTESTS: + # The number of times that the manually specified Python large dtests should be run. + REPEATED_LARGE_DTESTS_COUNT: 100 + # Comma-separated list of Python dtests that should be repeatedly run, for example: # REPEATED_UPGRADE_DTESTS: upgrade_tests/cql_tests.py # REPEATED_UPGRADE_DTESTS: upgrade_tests/cql_tests.py::TestCQLNodes2RF1_Upgrade_current_4_0_x_To_indev_4_0_x @@ -193,6 +202,12 @@ j11_small_executor: &j11_small_executor #exec_resource_class: medium parallelism: 1 +j11_medium_par_executor: &j11_medium_par_executor + executor: + name: java11-executor + #exec_resource_class: xlarge + parallelism: 1 + j11_seq_executor: &j11_seq_executor executor: name: java11-executor @@ -273,6 +288,30 @@ j8_separate_jobs: &j8_separate_jobs requires: - start_j8_jvm_dtests_vnode_repeat - j8_build + - start_j11_jvm_dtests: + type: approval + - j11_jvm_dtests: + requires: + - start_j11_jvm_dtests + - j8_build + - start_j11_jvm_dtests_vnode: + type: approval + - j11_jvm_dtests_vnode: + requires: + - start_j11_jvm_dtests_vnode + - j8_build + - start_j11_jvm_dtests_repeat: + type: approval + - j11_jvm_dtests_repeat: + requires: + - start_j11_jvm_dtests_repeat + - j8_build + - start_j11_jvm_dtests_vnode_repeat: + type: approval + - j11_jvm_dtests_vnode_repeat: + requires: + - start_j11_jvm_dtests_vnode_repeat + - j8_build - start_j8_simulator_dtests: type: approval - j8_simulator_dtests: @@ -291,6 +330,24 @@ j8_separate_jobs: &j8_separate_jobs requires: - start_j8_cqlshlib_tests - j8_build + - start_j8_cqlshlib_cython_tests: + type: approval + - j8_cqlshlib_cython_tests: + requires: + - start_j8_cqlshlib_cython_tests + - j8_build + - start_j11_cqlshlib_tests: + type: approval + - j11_cqlshlib_tests: + requires: + - start_j11_cqlshlib_tests + - j8_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j8_build # Java 11 unit tests - start_j11_unit_tests: type: approval @@ -467,7 +524,7 @@ j8_separate_jobs: &j8_separate_jobs requires: - start_jvm_upgrade_dtests_repeat - j8_dtest_jars_build - # Java 8 dtests + # Python DTests - start_j8_dtests: type: approval - j8_dtests: @@ -519,6 +576,55 @@ j8_separate_jobs: &j8_separate_jobs requires: - start_j11_dtests_offheap_repeat - j8_build + # Python large DTests + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_repeat: + type: approval + - j8_dtests_large_repeat: + requires: + - start_j8_dtests_large_repeat + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j8_dtests_large_vnode_repeat: + type: approval + - j8_dtests_large_vnode_repeat: + requires: + - start_j8_dtests_large_vnode_repeat + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_repeat: + type: approval + - j11_dtests_large_repeat: + requires: + - start_j11_dtests_large_repeat + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build + - start_j11_dtests_large_vnode_repeat: + type: approval + - j11_dtests_large_vnode_repeat: + requires: + - start_j11_dtests_large_vnode_repeat + - j8_build # Java 8 upgrade tests - start_upgrade_dtests: type: approval @@ -666,9 +772,30 @@ j8_pre-commit_jobs: &j8_pre-commit_jobs - j8_jvm_dtests_vnode_repeat: requires: - j8_build + - j11_jvm_dtests: + requires: + - j8_build + - j11_jvm_dtests_repeat: + requires: + - j8_build + - j11_jvm_dtests_vnode: + requires: + - j8_build + - j11_jvm_dtests_vnode_repeat: + requires: + - j8_build - j8_cqlshlib_tests: requires: - j8_build + - j8_cqlshlib_cython_tests: + requires: + - j8_build + - j11_cqlshlib_tests: + requires: + - j8_build + - j11_cqlshlib_cython_tests: + requires: + - j8_build # Java 11 unit tests - j11_unit_tests: requires: @@ -795,7 +922,7 @@ j8_pre-commit_jobs: &j8_pre-commit_jobs - j8_jvm_upgrade_dtests_repeat: requires: - j8_dtest_jars_build - # Java 8 dtests + # Python DTests - j8_dtests: requires: - j8_build @@ -841,6 +968,55 @@ j8_pre-commit_jobs: &j8_pre-commit_jobs requires: - start_j11_dtests_offheap - j8_build + # Large Python DTests + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_repeat: + type: approval + - j8_dtests_large_repeat: + requires: + - start_j8_dtests_large_repeat + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j8_dtests_large_vnode_repeat: + type: approval + - j8_dtests_large_vnode_repeat: + requires: + - start_j8_dtests_large_vnode_repeat + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_repeat: + type: approval + - j11_dtests_large_repeat: + requires: + - start_j11_dtests_large_repeat + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build + - start_j11_dtests_large_vnode_repeat: + type: approval + - j11_dtests_large_vnode_repeat: + requires: + - start_j11_dtests_large_vnode_repeat + - j8_build # Java 8 upgrade tests (on request) - start_upgrade_dtests: type: approval @@ -951,6 +1127,12 @@ j11_separate_jobs: &j11_separate_jobs requires: - start_j11_cqlshlib_tests - j11_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j11_build # Java 11 dtests - start_j11_dtests: type: approval @@ -976,6 +1158,30 @@ j11_separate_jobs: &j11_separate_jobs requires: - start_j11_dtests_offheap_repeat - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_repeat: + type: approval + - j11_dtests_large_repeat: + requires: + - start_j11_dtests_large_repeat + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build + - start_j11_dtests_large_vnode_repeat: + type: approval + - j11_dtests_large_vnode_repeat: + requires: + - start_j11_dtests_large_vnode_repeat + - j11_build - start_j11_cqlsh_tests: type: approval - j11_cqlsh_dtests_py3: @@ -1126,7 +1332,7 @@ j11_pre-commit_jobs: &j11_pre-commit_jobs - j11_cqlshlib_tests: requires: - j11_build - - j11_cqlshlib_tests: + - j11_cqlshlib_cython_tests: requires: - j11_build - j11_dtests: @@ -1153,6 +1359,30 @@ j11_pre-commit_jobs: &j11_pre-commit_jobs requires: - start_j11_dtests_offheap_repeat - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_repeat: + type: approval + - j11_dtests_large_repeat: + requires: + - start_j11_dtests_large_repeat + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build + - start_j11_dtests_large_vnode_repeat: + type: approval + - j11_dtests_large_vnode_repeat: + requires: + - start_j11_dtests_large_vnode_repeat + - j11_build - j11_cqlsh_dtests_py3: requires: - j11_build @@ -1411,6 +1641,13 @@ jobs: at: /home/cassandra - run_cqlshlib_tests + j8_cqlshlib_cython_tests: + <<: *j8_small_executor + steps: + - attach_workspace: + at: /home/cassandra + - run_cqlshlib_cython_tests + j11_cqlshlib_tests: <<: *j11_small_executor steps: @@ -1418,6 +1655,13 @@ jobs: at: /home/cassandra - run_cqlshlib_tests + j11_cqlshlib_cython_tests: + <<: *j11_small_executor + steps: + - attach_workspace: + at: /home/cassandra + - run_cqlshlib_cython_tests + j8_utests_long: <<: *j8_seq_executor steps: @@ -1825,6 +2069,62 @@ jobs: extra_env_args: 'CQLSH_PYTHON=/usr/bin/python3.8' python_version: '3.8' + j8_dtests_large_vnode: + <<: *j8_par_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - create_dtest_containers: + file_tag: j8_large_with_vnodes + run_dtests_extra_args: '--use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests' + - run_dtests: + file_tag: j8_large_with_vnodes + pytest_extra_args: '--use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests' + + j8_dtests_large: + <<: *j8_par_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - create_dtest_containers: + file_tag: j8_large_without_vnodes + run_dtests_extra_args: '--only-resource-intensive-tests --force-resource-intensive-tests' + - run_dtests: + file_tag: j8_large_without_vnodes + pytest_extra_args: '--only-resource-intensive-tests --force-resource-intensive-tests' + + j11_dtests_large_vnode: + <<: *j11_par_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - create_dtest_containers: + file_tag: j11_large_with_vnodes + run_dtests_extra_args: '--use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests' + - run_dtests: + file_tag: j11_large_with_vnodes + pytest_extra_args: '--use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests' + + j11_dtests_large: + <<: *j11_par_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - create_dtest_containers: + file_tag: j11_large_without_vnodes + run_dtests_extra_args: '--only-resource-intensive-tests --force-resource-intensive-tests' + - run_dtests: + file_tag: j11_large_without_vnodes + pytest_extra_args: '--only-resource-intensive-tests --force-resource-intensive-tests' + j8_unit_tests_repeat: <<: *j8_repeated_utest_executor steps: @@ -2056,6 +2356,36 @@ jobs: stop_on_failure: ${REPEATED_TESTS_STOP_ON_FAILURE} extra_dtest_args: "--use-off-heap-memtables --skip-resource-intensive-tests" + j8_dtests_large_repeat: + <<: *j8_repeated_dtest_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - run_repeated_dtest: + tests: ${REPEATED_LARGE_DTESTS} + vnodes: "false" + upgrade: "false" + count: ${REPEATED_LARGE_DTESTS_COUNT} + stop_on_failure: ${REPEATED_TESTS_STOP_ON_FAILURE} + extra_dtest_args: "--only-resource-intensive-tests --force-resource-intensive-tests" + + j8_dtests_large_vnode_repeat: + <<: *j8_repeated_dtest_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - run_repeated_dtest: + tests: ${REPEATED_LARGE_DTESTS} + vnodes: "true" + upgrade: "false" + count: ${REPEATED_LARGE_DTESTS_COUNT} + stop_on_failure: ${REPEATED_TESTS_STOP_ON_FAILURE} + extra_dtest_args: "--only-resource-intensive-tests --force-resource-intensive-tests" + j11_dtests_repeat: <<: *j11_repeated_dtest_executor steps: @@ -2101,6 +2431,36 @@ jobs: stop_on_failure: ${REPEATED_TESTS_STOP_ON_FAILURE} extra_dtest_args: "--use-off-heap-memtables --skip-resource-intensive-tests" + j11_dtests_large_repeat: + <<: *j11_repeated_dtest_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - run_repeated_dtest: + tests: ${REPEATED_LARGE_DTESTS} + vnodes: "false" + upgrade: "false" + count: ${REPEATED_LARGE_DTESTS_COUNT} + stop_on_failure: ${REPEATED_TESTS_STOP_ON_FAILURE} + extra_dtest_args: "--only-resource-intensive-tests --force-resource-intensive-tests" + + j11_dtests_large_vnode_repeat: + <<: *j11_repeated_dtest_executor + steps: + - attach_workspace: + at: /home/cassandra + - clone_dtest + - create_venv + - run_repeated_dtest: + tests: ${REPEATED_LARGE_DTESTS} + vnodes: "true" + upgrade: "false" + count: ${REPEATED_LARGE_DTESTS_COUNT} + stop_on_failure: ${REPEATED_TESTS_STOP_ON_FAILURE} + extra_dtest_args: "--only-resource-intensive-tests --force-resource-intensive-tests" + j8_upgrade_dtests_repeat: <<: *j8_repeated_upgrade_dtest_executor steps: @@ -2332,12 +2692,30 @@ commands: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: <> - store_test_results: path: /tmp/cassandra/pylib + run_cqlshlib_cython_tests: + parameters: + no_output_timeout: + type: string + default: 15m + steps: + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: <> + - store_test_results: + path: /tmp/cassandra/pylib + run_parallel_junit_tests: parameters: target: @@ -2480,7 +2858,12 @@ commands: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_<>_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest <> --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_<>.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest <> --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_<>.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -2875,7 +3258,7 @@ commands: default: "" steps: - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "<>" == "" ]; then diff --git a/.circleci/config-2_1.yml.high_res.patch b/.circleci/config-2_1.yml.high_res.patch index f4b5bd1428..ded21fff8c 100644 --- a/.circleci/config-2_1.yml.high_res.patch +++ b/.circleci/config-2_1.yml.high_res.patch @@ -1,6 +1,6 @@ ---- config-2_1.yml 2022-11-07 22:46:12.000000000 -0500 -+++ config-2_1.yml.HIGHRES 2022-11-07 22:55:05.000000000 -0500 -@@ -148,14 +148,14 @@ +--- config-2_1.yml 2022-11-15 12:30:50.000000000 -0500 ++++ config-2_1.yml.HIGHRES 2022-11-15 12:35:46.000000000 -0500 +@@ -157,14 +157,14 @@ j8_par_executor: &j8_par_executor executor: name: java8-executor @@ -19,7 +19,7 @@ j8_small_executor: &j8_small_executor executor: -@@ -166,68 +166,74 @@ +@@ -175,74 +175,80 @@ j8_medium_par_executor: &j8_medium_par_executor executor: name: java8-executor @@ -43,23 +43,29 @@ + exec_resource_class: xlarge + parallelism: 100 --j11_small_par_executor: &j11_small_par_executor -+j11_small_executor: &j11_small_executor + j11_small_par_executor: &j11_small_par_executor executor: name: java11-executor - #exec_resource_class: xlarge -+ exec_resource_class: medium - parallelism: 1 - --j11_small_executor: &j11_small_executor -+j11_small_par_executor: &j11_small_par_executor - executor: - name: java11-executor -- #exec_resource_class: medium - parallelism: 1 + exec_resource_class: xlarge + parallelism: 5 + j11_small_executor: &j11_small_executor + executor: + name: java11-executor +- #exec_resource_class: medium ++ exec_resource_class: medium + parallelism: 1 + + j11_medium_par_executor: &j11_medium_par_executor + executor: + name: java11-executor +- #exec_resource_class: xlarge +- parallelism: 1 ++ exec_resource_class: xlarge ++ parallelism: 2 + j11_seq_executor: &j11_seq_executor executor: name: java11-executor @@ -111,3 +117,39 @@ j8_separate_jobs: &j8_separate_jobs jobs: +@@ -2070,7 +2076,7 @@ + python_version: '3.8' + + j8_dtests_large_vnode: +- <<: *j8_par_executor ++ <<: *j8_seq_executor + steps: + - attach_workspace: + at: /home/cassandra +@@ -2084,7 +2090,7 @@ + pytest_extra_args: '--use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests' + + j8_dtests_large: +- <<: *j8_par_executor ++ <<: *j8_seq_executor + steps: + - attach_workspace: + at: /home/cassandra +@@ -2098,7 +2104,7 @@ + pytest_extra_args: '--only-resource-intensive-tests --force-resource-intensive-tests' + + j11_dtests_large_vnode: +- <<: *j11_par_executor ++ <<: *j11_seq_executor + steps: + - attach_workspace: + at: /home/cassandra +@@ -2112,7 +2118,7 @@ + pytest_extra_args: '--use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests' + + j11_dtests_large: +- <<: *j11_par_executor ++ <<: *j11_seq_executor + steps: + - attach_workspace: + at: /home/cassandra diff --git a/.circleci/config-2_1.yml.mid_res.patch b/.circleci/config-2_1.yml.mid_res.patch index 55f637d739..3325f39485 100644 --- a/.circleci/config-2_1.yml.mid_res.patch +++ b/.circleci/config-2_1.yml.mid_res.patch @@ -1,6 +1,6 @@ ---- config-2_1.yml 2022-11-08 17:14:23.000000000 -0500 -+++ config-2_1.yml.MIDRES 2022-11-08 17:39:30.000000000 -0500 -@@ -148,14 +148,14 @@ +--- config-2_1.yml 2022-11-15 12:30:50.000000000 -0500 ++++ config-2_1.yml.MIDRES 2022-11-15 12:35:46.000000000 -0500 +@@ -157,14 +157,14 @@ j8_par_executor: &j8_par_executor executor: name: java8-executor @@ -19,7 +19,7 @@ j8_small_executor: &j8_small_executor executor: -@@ -163,29 +163,41 @@ +@@ -172,29 +172,41 @@ exec_resource_class: medium parallelism: 1 @@ -68,16 +68,21 @@ j11_small_executor: &j11_small_executor executor: -@@ -193,41 +205,53 @@ - #exec_resource_class: medium - parallelism: 1 - +@@ -205,44 +217,56 @@ + j11_medium_par_executor: &j11_medium_par_executor + executor: + name: java11-executor +- #exec_resource_class: xlarge +- parallelism: 1 ++ exec_resource_class: large ++ parallelism: 4 ++ +j11_large_par_executor: &j11_large_par_executor + executor: + name: java11-executor + exec_resource_class: large + parallelism: 50 -+ + j11_seq_executor: &j11_seq_executor executor: name: java11-executor @@ -129,7 +134,7 @@ j8_separate_jobs: &j8_separate_jobs jobs: -@@ -1527,7 +1551,7 @@ +@@ -1771,7 +1795,7 @@ target: testclasslist-system-keyspace-directory j8_dtests_vnode: @@ -138,7 +143,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1541,7 +1565,7 @@ +@@ -1785,7 +1809,7 @@ pytest_extra_args: '--use-vnodes --num-tokens=16 --skip-resource-intensive-tests' j8_dtests_offheap: @@ -147,7 +152,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1555,7 +1579,7 @@ +@@ -1799,7 +1823,7 @@ pytest_extra_args: '--use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests' j11_dtests_vnode: @@ -156,7 +161,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1570,7 +1594,7 @@ +@@ -1814,7 +1838,7 @@ pytest_extra_args: '--use-vnodes --num-tokens=16 --skip-resource-intensive-tests' j11_dtests_offheap: @@ -165,7 +170,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1585,7 +1609,7 @@ +@@ -1829,7 +1853,7 @@ pytest_extra_args: '--use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests' j8_dtests: @@ -174,7 +179,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1599,7 +1623,7 @@ +@@ -1843,7 +1867,7 @@ pytest_extra_args: '--skip-resource-intensive-tests' j11_dtests: @@ -183,7 +188,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1614,7 +1638,7 @@ +@@ -1858,7 +1882,7 @@ pytest_extra_args: '--skip-resource-intensive-tests' j8_upgrade_dtests: @@ -192,7 +197,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1628,7 +1652,7 @@ +@@ -1872,7 +1896,7 @@ pytest_extra_args: '--execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all' j8_cqlsh_dtests_py3_vnode: @@ -201,7 +206,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1643,7 +1667,7 @@ +@@ -1887,7 +1911,7 @@ extra_env_args: 'CQLSH_PYTHON=/usr/bin/python3.6' j8_cqlsh_dtests_py3_offheap: @@ -210,7 +215,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1658,7 +1682,7 @@ +@@ -1902,7 +1926,7 @@ extra_env_args: 'CQLSH_PYTHON=/usr/bin/python3.6' j8_cqlsh_dtests_py38_vnode: @@ -219,7 +224,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1676,7 +1700,7 @@ +@@ -1920,7 +1944,7 @@ python_version: '3.8' j8_cqlsh_dtests_py38_offheap: @@ -228,7 +233,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1694,7 +1718,7 @@ +@@ -1938,7 +1962,7 @@ python_version: '3.8' j8_cqlsh_dtests_py3: @@ -237,7 +242,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1709,7 +1733,7 @@ +@@ -1953,7 +1977,7 @@ extra_env_args: 'CQLSH_PYTHON=/usr/bin/python3.6' j8_cqlsh_dtests_py38: @@ -246,7 +251,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1727,7 +1751,7 @@ +@@ -1971,7 +1995,7 @@ python_version: '3.8' j11_cqlsh_dtests_py3_vnode: @@ -255,7 +260,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1742,7 +1766,7 @@ +@@ -1986,7 +2010,7 @@ extra_env_args: 'CQLSH_PYTHON=/usr/bin/python3.6' j11_cqlsh_dtests_py3_offheap: @@ -264,7 +269,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1757,7 +1781,7 @@ +@@ -2001,7 +2025,7 @@ extra_env_args: 'CQLSH_PYTHON=/usr/bin/python3.6' j11_cqlsh_dtests_py38_vnode: @@ -273,7 +278,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1775,7 +1799,7 @@ +@@ -2019,7 +2043,7 @@ python_version: '3.8' j11_cqlsh_dtests_py38_offheap: @@ -282,7 +287,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1793,7 +1817,7 @@ +@@ -2037,7 +2061,7 @@ python_version: '3.8' j11_cqlsh_dtests_py3: @@ -291,7 +296,7 @@ steps: - attach_workspace: at: /home/cassandra -@@ -1808,7 +1832,7 @@ +@@ -2052,7 +2076,7 @@ extra_env_args: 'CQLSH_PYTHON=/usr/bin/python3.6' j11_cqlsh_dtests_py38: @@ -300,3 +305,39 @@ steps: - attach_workspace: at: /home/cassandra +@@ -2070,7 +2094,7 @@ + python_version: '3.8' + + j8_dtests_large_vnode: +- <<: *j8_par_executor ++ <<: *j8_medium_par_executor + steps: + - attach_workspace: + at: /home/cassandra +@@ -2084,7 +2108,7 @@ + pytest_extra_args: '--use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests' + + j8_dtests_large: +- <<: *j8_par_executor ++ <<: *j8_medium_par_executor + steps: + - attach_workspace: + at: /home/cassandra +@@ -2098,7 +2122,7 @@ + pytest_extra_args: '--only-resource-intensive-tests --force-resource-intensive-tests' + + j11_dtests_large_vnode: +- <<: *j11_par_executor ++ <<: *j11_medium_par_executor + steps: + - attach_workspace: + at: /home/cassandra +@@ -2112,7 +2136,7 @@ + pytest_extra_args: '--use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests' + + j11_dtests_large: +- <<: *j11_par_executor ++ <<: *j11_medium_par_executor + steps: + - attach_workspace: + at: /home/cassandra diff --git a/.circleci/config.yml b/.circleci/config.yml index 7f069254dc..323567f960 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -126,6 +126,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -215,6 +217,74 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -274,7 +344,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -370,6 +440,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -380,6 +452,92 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_with_vnodes_raw /tmp/all_dtest_tests_j8_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_with_vnodes_raw > /tmp/all_dtest_tests_j8_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_with_vnodes > /tmp/split_dtest_tests_j8_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_system_keyspace_directory: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -488,6 +646,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -560,6 +720,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -649,6 +811,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -767,6 +931,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -856,6 +1022,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -973,6 +1141,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1035,7 +1205,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1077,6 +1252,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1138,7 +1315,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1180,6 +1362,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1270,6 +1454,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1464,6 +1650,230 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_with_vnodes_raw /tmp/all_dtest_tests_j11_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_with_vnodes_raw > /tmp/all_dtest_tests_j11_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_with_vnodes > /tmp/split_dtest_tests_j11_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1526,7 +1936,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1568,6 +1983,95 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_without_vnodes_raw /tmp/all_dtest_tests_j11_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_without_vnodes_raw > /tmp/all_dtest_tests_j11_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_without_vnodes > /tmp/split_dtest_tests_j11_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1658,6 +2162,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1720,7 +2226,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1762,6 +2273,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1823,7 +2336,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1865,6 +2383,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1875,6 +2395,71 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_cdc: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -1983,6 +2568,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2055,6 +2642,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2173,6 +2762,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2209,7 +2800,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2305,6 +2896,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2341,7 +2934,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2437,6 +3030,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2447,6 +3042,140 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_jvm_dtests_vnode: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -2555,6 +3284,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2669,6 +3400,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2786,6 +3519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2857,6 +3592,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2947,6 +3684,94 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_without_vnodes_raw /tmp/all_dtest_tests_j8_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_without_vnodes_raw > /tmp/all_dtest_tests_j8_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_without_vnodes > /tmp/split_dtest_tests_j8_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3018,6 +3843,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3080,7 +3907,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3122,6 +3954,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3158,7 +3992,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_UPGRADE_DTESTS}" == "" ]; then @@ -3254,6 +4088,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3343,6 +4179,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3402,7 +4240,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -3498,6 +4336,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3588,6 +4428,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3677,6 +4519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3794,6 +4638,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3856,7 +4702,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3898,6 +4749,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3959,7 +4812,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4001,6 +4859,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4091,6 +4951,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4180,6 +5042,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4189,6 +5053,141 @@ jobs: - REPEATED_ANT_TEST_COUNT: 500 - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j11_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true j8_cqlsh_dtests_py3_offheap: docker: - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest @@ -4241,7 +5240,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4283,6 +5287,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4372,6 +5378,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4408,7 +5416,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -4504,6 +5512,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4565,7 +5575,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4607,6 +5622,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4650,7 +5667,7 @@ jobs: - run: name: Run dtests (j8_upgradetests_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4692,6 +5709,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4756,7 +5775,7 @@ jobs: - run: name: Run dtests (j11_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4798,6 +5817,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4888,6 +5909,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4949,7 +5972,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4991,6 +6019,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5081,6 +6111,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5171,6 +6203,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5213,7 +6247,7 @@ jobs: - run: name: Run dtests (j8_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5255,6 +6289,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5372,6 +6408,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5489,6 +6527,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5579,6 +6619,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5686,6 +6728,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5729,7 +6773,7 @@ jobs: - run: name: Run dtests (j8_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5771,6 +6815,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5813,7 +6859,7 @@ jobs: - run: name: Run dtests (j8_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5855,6 +6901,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5879,8 +6927,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -5917,6 +6965,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6007,6 +7057,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6071,7 +7123,7 @@ jobs: - run: name: Run dtests (j11_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -6113,6 +7165,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6307,6 +7361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6378,6 +7434,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6495,6 +7553,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6531,7 +7591,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -6627,6 +7687,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6744,6 +7806,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6850,6 +7914,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6911,7 +7977,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -6953,6 +8024,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7042,6 +8115,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7114,6 +8189,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7138,8 +8215,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -7176,6 +8253,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7240,7 +8319,7 @@ jobs: - run: name: Run dtests (j11_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -7282,6 +8361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7372,6 +8453,142 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7461,6 +8678,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7565,6 +8784,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7601,6 +8822,18 @@ workflows: requires: - start_j8_jvm_dtests_vnode - j8_build + - start_j11_jvm_dtests: + type: approval + - j11_jvm_dtests: + requires: + - start_j11_jvm_dtests + - j8_build + - start_j11_jvm_dtests_vnode: + type: approval + - j11_jvm_dtests_vnode: + requires: + - start_j11_jvm_dtests_vnode + - j8_build - start_j8_simulator_dtests: type: approval - j8_simulator_dtests: @@ -7613,6 +8846,24 @@ workflows: requires: - start_j8_cqlshlib_tests - j8_build + - start_j8_cqlshlib_cython_tests: + type: approval + - j8_cqlshlib_cython_tests: + requires: + - start_j8_cqlshlib_cython_tests + - j8_build + - start_j11_cqlshlib_tests: + type: approval + - j11_cqlshlib_tests: + requires: + - start_j11_cqlshlib_tests + - j8_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j8_build - start_j11_unit_tests: type: approval - j11_unit_tests: @@ -7739,6 +8990,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7820,9 +9095,24 @@ workflows: - j8_jvm_dtests_vnode: requires: - j8_build + - j11_jvm_dtests: + requires: + - j8_build + - j11_jvm_dtests_vnode: + requires: + - j8_build - j8_cqlshlib_tests: requires: - j8_build + - j8_cqlshlib_cython_tests: + requires: + - j8_build + - j11_cqlshlib_tests: + requires: + - j8_build + - j11_cqlshlib_cython_tests: + requires: + - j8_build - j11_unit_tests: requires: - j8_build @@ -7918,6 +9208,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7999,6 +9313,12 @@ workflows: requires: - start_j11_cqlshlib_tests - j11_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j11_build - start_j11_dtests: type: approval - j11_dtests: @@ -8017,6 +9337,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - start_j11_cqlsh_tests: type: approval - j11_cqlsh_dtests_py3: @@ -8100,7 +9432,7 @@ workflows: - j11_cqlshlib_tests: requires: - j11_build - - j11_cqlshlib_tests: + - j11_cqlshlib_cython_tests: requires: - j11_build - j11_dtests: @@ -8115,6 +9447,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - j11_cqlsh_dtests_py3: requires: - j11_build diff --git a/.circleci/config.yml.HIGHRES b/.circleci/config.yml.HIGHRES index 078097eebf..219586716f 100644 --- a/.circleci/config.yml.HIGHRES +++ b/.circleci/config.yml.HIGHRES @@ -126,6 +126,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -215,6 +217,74 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -274,7 +344,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -370,6 +440,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -380,6 +452,92 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_with_vnodes_raw /tmp/all_dtest_tests_j8_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_with_vnodes_raw > /tmp/all_dtest_tests_j8_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_with_vnodes > /tmp/split_dtest_tests_j8_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_system_keyspace_directory: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -488,6 +646,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -560,6 +720,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -649,6 +811,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -767,6 +931,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -856,6 +1022,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -973,6 +1141,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1035,7 +1205,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1077,6 +1252,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1138,7 +1315,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1180,6 +1362,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1270,6 +1454,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1464,6 +1650,230 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_with_vnodes_raw /tmp/all_dtest_tests_j11_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_with_vnodes_raw > /tmp/all_dtest_tests_j11_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_with_vnodes > /tmp/split_dtest_tests_j11_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 100 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1526,7 +1936,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1568,6 +1983,95 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_without_vnodes_raw /tmp/all_dtest_tests_j11_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_without_vnodes_raw > /tmp/all_dtest_tests_j11_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_without_vnodes > /tmp/split_dtest_tests_j11_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1658,6 +2162,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1720,7 +2226,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1762,6 +2273,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1823,7 +2336,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1865,6 +2383,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1875,6 +2395,71 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_cdc: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -1983,6 +2568,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2055,6 +2642,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2173,6 +2762,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2209,7 +2800,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2305,6 +2896,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2341,7 +2934,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2437,6 +3030,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2447,6 +3042,140 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 100 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_jvm_dtests_vnode: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -2555,6 +3284,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2669,6 +3400,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2786,6 +3519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2857,6 +3592,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2947,6 +3684,94 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_without_vnodes_raw /tmp/all_dtest_tests_j8_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_without_vnodes_raw > /tmp/all_dtest_tests_j8_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_without_vnodes > /tmp/split_dtest_tests_j8_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3018,6 +3843,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3080,7 +3907,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3122,6 +3954,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3158,7 +3992,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_UPGRADE_DTESTS}" == "" ]; then @@ -3254,6 +4088,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3343,6 +4179,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3402,7 +4240,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -3498,6 +4336,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3588,6 +4428,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3677,6 +4519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3794,6 +4638,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3856,7 +4702,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3898,6 +4749,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3959,7 +4812,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4001,6 +4859,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4091,6 +4951,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4180,6 +5042,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4189,6 +5053,141 @@ jobs: - REPEATED_ANT_TEST_COUNT: 500 - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j11_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 100 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true j8_cqlsh_dtests_py3_offheap: docker: - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest @@ -4241,7 +5240,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4283,6 +5287,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4372,6 +5378,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4408,7 +5416,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -4504,6 +5512,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4565,7 +5575,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4607,6 +5622,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4650,7 +5667,7 @@ jobs: - run: name: Run dtests (j8_upgradetests_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4692,6 +5709,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4756,7 +5775,7 @@ jobs: - run: name: Run dtests (j11_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4798,6 +5817,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4888,6 +5909,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4949,7 +5972,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4991,6 +6019,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5081,6 +6111,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5171,6 +6203,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5213,7 +6247,7 @@ jobs: - run: name: Run dtests (j8_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5255,6 +6289,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5372,6 +6408,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5489,6 +6527,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5579,6 +6619,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5686,6 +6728,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5729,7 +6773,7 @@ jobs: - run: name: Run dtests (j8_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5771,6 +6815,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5813,7 +6859,7 @@ jobs: - run: name: Run dtests (j8_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5855,6 +6901,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5879,8 +6927,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -5917,6 +6965,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6007,6 +7057,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6071,7 +7123,7 @@ jobs: - run: name: Run dtests (j11_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -6113,6 +7165,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6307,6 +7361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6378,6 +7434,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6495,6 +7553,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6531,7 +7591,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -6627,6 +7687,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6744,6 +7806,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6850,6 +7914,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6911,7 +7977,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -6953,6 +8024,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7042,6 +8115,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7114,6 +8189,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7138,8 +8215,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -7176,6 +8253,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7240,7 +8319,7 @@ jobs: - run: name: Run dtests (j11_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -7282,6 +8361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7372,6 +8453,142 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: xlarge + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 100 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7461,6 +8678,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7565,6 +8784,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7601,6 +8822,18 @@ workflows: requires: - start_j8_jvm_dtests_vnode - j8_build + - start_j11_jvm_dtests: + type: approval + - j11_jvm_dtests: + requires: + - start_j11_jvm_dtests + - j8_build + - start_j11_jvm_dtests_vnode: + type: approval + - j11_jvm_dtests_vnode: + requires: + - start_j11_jvm_dtests_vnode + - j8_build - start_j8_simulator_dtests: type: approval - j8_simulator_dtests: @@ -7613,6 +8846,24 @@ workflows: requires: - start_j8_cqlshlib_tests - j8_build + - start_j8_cqlshlib_cython_tests: + type: approval + - j8_cqlshlib_cython_tests: + requires: + - start_j8_cqlshlib_cython_tests + - j8_build + - start_j11_cqlshlib_tests: + type: approval + - j11_cqlshlib_tests: + requires: + - start_j11_cqlshlib_tests + - j8_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j8_build - start_j11_unit_tests: type: approval - j11_unit_tests: @@ -7739,6 +8990,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7820,9 +9095,24 @@ workflows: - j8_jvm_dtests_vnode: requires: - j8_build + - j11_jvm_dtests: + requires: + - j8_build + - j11_jvm_dtests_vnode: + requires: + - j8_build - j8_cqlshlib_tests: requires: - j8_build + - j8_cqlshlib_cython_tests: + requires: + - j8_build + - j11_cqlshlib_tests: + requires: + - j8_build + - j11_cqlshlib_cython_tests: + requires: + - j8_build - j11_unit_tests: requires: - j8_build @@ -7918,6 +9208,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7999,6 +9313,12 @@ workflows: requires: - start_j11_cqlshlib_tests - j11_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j11_build - start_j11_dtests: type: approval - j11_dtests: @@ -8017,6 +9337,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - start_j11_cqlsh_tests: type: approval - j11_cqlsh_dtests_py3: @@ -8100,7 +9432,7 @@ workflows: - j11_cqlshlib_tests: requires: - j11_build - - j11_cqlshlib_tests: + - j11_cqlshlib_cython_tests: requires: - j11_build - j11_dtests: @@ -8115,6 +9447,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - j11_cqlsh_dtests_py3: requires: - j11_build diff --git a/.circleci/config.yml.LOWRES b/.circleci/config.yml.LOWRES index 7f069254dc..323567f960 100644 --- a/.circleci/config.yml.LOWRES +++ b/.circleci/config.yml.LOWRES @@ -126,6 +126,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -215,6 +217,74 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -274,7 +344,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -370,6 +440,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -380,6 +452,92 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_with_vnodes_raw /tmp/all_dtest_tests_j8_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_with_vnodes_raw > /tmp/all_dtest_tests_j8_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_with_vnodes > /tmp/split_dtest_tests_j8_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_system_keyspace_directory: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -488,6 +646,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -560,6 +720,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -649,6 +811,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -767,6 +931,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -856,6 +1022,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -973,6 +1141,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1035,7 +1205,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1077,6 +1252,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1138,7 +1315,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1180,6 +1362,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1270,6 +1454,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1464,6 +1650,230 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_with_vnodes_raw /tmp/all_dtest_tests_j11_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_with_vnodes_raw > /tmp/all_dtest_tests_j11_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_with_vnodes > /tmp/split_dtest_tests_j11_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1526,7 +1936,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1568,6 +1983,95 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_without_vnodes_raw /tmp/all_dtest_tests_j11_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_without_vnodes_raw > /tmp/all_dtest_tests_j11_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_without_vnodes > /tmp/split_dtest_tests_j11_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1658,6 +2162,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1720,7 +2226,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1762,6 +2273,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1823,7 +2336,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1865,6 +2383,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1875,6 +2395,71 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_cdc: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -1983,6 +2568,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2055,6 +2642,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2173,6 +2762,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2209,7 +2800,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2305,6 +2896,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2341,7 +2934,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2437,6 +3030,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2447,6 +3042,140 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_jvm_dtests_vnode: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -2555,6 +3284,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2669,6 +3400,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2786,6 +3519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2857,6 +3592,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2947,6 +3684,94 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_without_vnodes_raw /tmp/all_dtest_tests_j8_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_without_vnodes_raw > /tmp/all_dtest_tests_j8_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_without_vnodes > /tmp/split_dtest_tests_j8_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3018,6 +3843,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3080,7 +3907,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3122,6 +3954,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3158,7 +3992,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_UPGRADE_DTESTS}" == "" ]; then @@ -3254,6 +4088,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3343,6 +4179,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3402,7 +4240,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -3498,6 +4336,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3588,6 +4428,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3677,6 +4519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3794,6 +4638,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3856,7 +4702,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3898,6 +4749,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3959,7 +4812,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4001,6 +4859,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4091,6 +4951,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4180,6 +5042,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4189,6 +5053,141 @@ jobs: - REPEATED_ANT_TEST_COUNT: 500 - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j11_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true j8_cqlsh_dtests_py3_offheap: docker: - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest @@ -4241,7 +5240,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4283,6 +5287,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4372,6 +5378,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4408,7 +5416,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -4504,6 +5512,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4565,7 +5575,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4607,6 +5622,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4650,7 +5667,7 @@ jobs: - run: name: Run dtests (j8_upgradetests_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4692,6 +5709,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4756,7 +5775,7 @@ jobs: - run: name: Run dtests (j11_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4798,6 +5817,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4888,6 +5909,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4949,7 +5972,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4991,6 +6019,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5081,6 +6111,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5171,6 +6203,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5213,7 +6247,7 @@ jobs: - run: name: Run dtests (j8_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5255,6 +6289,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5372,6 +6408,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5489,6 +6527,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5579,6 +6619,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5686,6 +6728,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5729,7 +6773,7 @@ jobs: - run: name: Run dtests (j8_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5771,6 +6815,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5813,7 +6859,7 @@ jobs: - run: name: Run dtests (j8_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5855,6 +6901,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5879,8 +6927,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -5917,6 +6965,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6007,6 +7057,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6071,7 +7123,7 @@ jobs: - run: name: Run dtests (j11_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -6113,6 +7165,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6307,6 +7361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6378,6 +7434,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6495,6 +7553,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6531,7 +7591,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -6627,6 +7687,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6744,6 +7806,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6850,6 +7914,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6911,7 +7977,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -6953,6 +8024,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7042,6 +8115,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7114,6 +8189,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7138,8 +8215,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -7176,6 +8253,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7240,7 +8319,7 @@ jobs: - run: name: Run dtests (j11_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -7282,6 +8361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7372,6 +8453,142 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7461,6 +8678,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7565,6 +8784,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7601,6 +8822,18 @@ workflows: requires: - start_j8_jvm_dtests_vnode - j8_build + - start_j11_jvm_dtests: + type: approval + - j11_jvm_dtests: + requires: + - start_j11_jvm_dtests + - j8_build + - start_j11_jvm_dtests_vnode: + type: approval + - j11_jvm_dtests_vnode: + requires: + - start_j11_jvm_dtests_vnode + - j8_build - start_j8_simulator_dtests: type: approval - j8_simulator_dtests: @@ -7613,6 +8846,24 @@ workflows: requires: - start_j8_cqlshlib_tests - j8_build + - start_j8_cqlshlib_cython_tests: + type: approval + - j8_cqlshlib_cython_tests: + requires: + - start_j8_cqlshlib_cython_tests + - j8_build + - start_j11_cqlshlib_tests: + type: approval + - j11_cqlshlib_tests: + requires: + - start_j11_cqlshlib_tests + - j8_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j8_build - start_j11_unit_tests: type: approval - j11_unit_tests: @@ -7739,6 +8990,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7820,9 +9095,24 @@ workflows: - j8_jvm_dtests_vnode: requires: - j8_build + - j11_jvm_dtests: + requires: + - j8_build + - j11_jvm_dtests_vnode: + requires: + - j8_build - j8_cqlshlib_tests: requires: - j8_build + - j8_cqlshlib_cython_tests: + requires: + - j8_build + - j11_cqlshlib_tests: + requires: + - j8_build + - j11_cqlshlib_cython_tests: + requires: + - j8_build - j11_unit_tests: requires: - j8_build @@ -7918,6 +9208,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7999,6 +9313,12 @@ workflows: requires: - start_j11_cqlshlib_tests - j11_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j11_build - start_j11_dtests: type: approval - j11_dtests: @@ -8017,6 +9337,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - start_j11_cqlsh_tests: type: approval - j11_cqlsh_dtests_py3: @@ -8100,7 +9432,7 @@ workflows: - j11_cqlshlib_tests: requires: - j11_build - - j11_cqlshlib_tests: + - j11_cqlshlib_cython_tests: requires: - j11_build - j11_dtests: @@ -8115,6 +9447,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - j11_cqlsh_dtests_py3: requires: - j11_build diff --git a/.circleci/config.yml.MIDRES b/.circleci/config.yml.MIDRES index 2c94d5bde2..f6fae8753e 100644 --- a/.circleci/config.yml.MIDRES +++ b/.circleci/config.yml.MIDRES @@ -126,6 +126,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -215,6 +217,74 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -274,7 +344,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -370,6 +440,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -380,6 +452,92 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_with_vnodes_raw /tmp/all_dtest_tests_j8_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_with_vnodes_raw > /tmp/all_dtest_tests_j8_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_with_vnodes > /tmp/split_dtest_tests_j8_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_system_keyspace_directory: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -488,6 +646,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -560,6 +720,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -649,6 +811,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -767,6 +931,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -856,6 +1022,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -973,6 +1141,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1035,7 +1205,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1077,6 +1252,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1138,7 +1315,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1180,6 +1362,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1270,6 +1454,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1464,6 +1650,230 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_with_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_with_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --use-vnodes --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_with_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_with_vnodes_raw /tmp/all_dtest_tests_j11_large_with_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_with_vnodes_raw > /tmp/all_dtest_tests_j11_large_with_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_with_vnodes > /tmp/split_dtest_tests_j11_large_with_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_with_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_with_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_with_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 25 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1526,7 +1936,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1568,6 +1983,95 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true + j11_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j11_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j11_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j11_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j11_large_without_vnodes_raw /tmp/all_dtest_tests_j11_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j11_large_without_vnodes_raw > /tmp/all_dtest_tests_j11_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j11_large_without_vnodes > /tmp/split_dtest_tests_j11_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j11_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j11_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j11_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1658,6 +2162,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1720,7 +2226,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1762,6 +2273,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1823,7 +2336,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -1865,6 +2383,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -1875,6 +2395,71 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_cqlshlib_cython_tests: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: medium + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 1 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Run cqlshlib Unit Tests + command: | + export PATH=$JAVA_HOME/bin:$PATH + export cython="yes" + time mv ~/cassandra /tmp + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) + no_output_timeout: 15m + - store_test_results: + path: /tmp/cassandra/pylib + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_utests_cdc: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -1983,6 +2568,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2055,6 +2642,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2173,6 +2762,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2209,7 +2800,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2305,6 +2896,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2341,7 +2934,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -2437,6 +3030,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2447,6 +3042,140 @@ jobs: - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 - CASSANDRA_USE_JDK11: true + j8_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 25 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 j11_jvm_dtests_vnode: docker: - image: apache/cassandra-testing-ubuntu2004-java11:latest @@ -2555,6 +3284,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2669,6 +3400,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2786,6 +3519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2857,6 +3592,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -2947,6 +3684,94 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 4 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Determine Tests to Run (j8_large_without_vnodes) + no_output_timeout: 5m + command: "# reminder: this code (along with all the steps) is independently executed on every circle container\n# so the goal here is to get the circleci script to return the tests *this* container will run\n# which we do via the `circleci` cli tool.\n\ncd cassandra-dtest\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\n\nif [ -n '' ]; then\n export \nfi\n\necho \"***Collected DTests (j8_large_without_vnodes)***\"\nset -eo pipefail && ./run_dtests.py --only-resource-intensive-tests --force-resource-intensive-tests --dtest-print-tests-only --dtest-print-tests-output=/tmp/all_dtest_tests_j8_large_without_vnodes_raw --cassandra-dir=../cassandra\nif [ -z '' ]; then\n mv /tmp/all_dtest_tests_j8_large_without_vnodes_raw /tmp/all_dtest_tests_j8_large_without_vnodes\nelse\n grep -e '' /tmp/all_dtest_tests_j8_large_without_vnodes_raw > /tmp/all_dtest_tests_j8_large_without_vnodes || { echo \"Filter did not match any tests! Exiting build.\"; exit 0; }\nfi\nset -eo pipefail && circleci tests split --split-by=timings --timings-type=classname /tmp/all_dtest_tests_j8_large_without_vnodes > /tmp/split_dtest_tests_j8_large_without_vnodes.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes.txt | tr '\\n' ' ' > /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n" + - run: + name: Run dtests (j8_large_without_vnodes) + no_output_timeout: 15m + command: "echo \"cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_large_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --only-resource-intensive-tests --force-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_large_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest_j8_large_without_vnodes + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_j8_large_without_vnodes_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3018,6 +3843,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3080,7 +3907,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3122,6 +3954,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3158,7 +3992,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_UPGRADE_DTESTS}" == "" ]; then @@ -3254,6 +4088,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3343,6 +4179,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3402,7 +4240,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -3498,6 +4336,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3588,6 +4428,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3677,6 +4519,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3794,6 +4638,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3856,7 +4702,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -3898,6 +4749,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -3959,7 +4812,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4001,6 +4859,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4091,6 +4951,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4180,6 +5042,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4189,6 +5053,141 @@ jobs: - REPEATED_ANT_TEST_COUNT: 500 - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j11_dtests_large_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 25 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if false; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - CASSANDRA_USE_JDK11: true j8_cqlsh_dtests_py3_offheap: docker: - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest @@ -4241,7 +5240,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4283,6 +5287,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4372,6 +5378,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4408,7 +5416,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -4504,6 +5512,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4565,7 +5575,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4607,6 +5622,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4650,7 +5667,7 @@ jobs: - run: name: Run dtests (j8_upgradetests_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_upgradetests_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --execute-upgrade-tests-only --upgrade-target-version-only --upgrade-version-selection all --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_upgradetests_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4692,6 +5709,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4756,7 +5775,7 @@ jobs: - run: name: Run dtests (j11_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -4798,6 +5817,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4888,6 +5909,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -4949,7 +5972,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -4991,6 +6019,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5081,6 +6111,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5171,6 +6203,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5213,7 +6247,7 @@ jobs: - run: name: Run dtests (j8_dtests_offheap) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\"\ncat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_dtests_offheap_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --use-off-heap-memtables --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_dtests_offheap.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5255,6 +6289,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5372,6 +6408,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5489,6 +6527,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5579,6 +6619,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5686,6 +6728,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5729,7 +6773,7 @@ jobs: - run: name: Run dtests (j8_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5771,6 +6815,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5813,7 +6859,7 @@ jobs: - run: name: Run dtests (j8_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j8_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -5855,6 +6901,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -5879,8 +6927,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -5917,6 +6965,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6007,6 +7057,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6071,7 +7123,7 @@ jobs: - run: name: Run dtests (j11_without_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_without_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_without_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_without_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -6113,6 +7165,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6307,6 +7361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6378,6 +7434,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6495,6 +7553,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6531,7 +7591,7 @@ jobs: pip3 uninstall -y cqlsh pip3 freeze - run: - name: Run repeated Python dtest + name: Run repeated Python DTests no_output_timeout: 15m command: | if [ "${REPEATED_DTESTS}" == "" ]; then @@ -6627,6 +7687,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6744,6 +7806,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6850,6 +7914,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -6911,7 +7977,12 @@ jobs: mkdir -p /tmp/results/dtests # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee export SPLIT_TESTS=`cat /tmp/split_dtest_tests_j8_with_vnodes_final.txt` - set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + if [ ! -z "$SPLIT_TESTS" ]; then + set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level="DEBUG" --junit-xml=/tmp/results/dtests/pytest_result_j8_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt + else + echo "Tune your parallelism, there are more containers than test classes. Nothing to do in this container" + (exit 1) + fi - store_test_results: path: /tmp/results - store_artifacts: @@ -6953,6 +8024,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7042,6 +8115,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7114,6 +8189,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7138,8 +8215,8 @@ jobs: command: | export PATH=$JAVA_HOME/bin:$PATH time mv ~/cassandra /tmp - cd /tmp/cassandra/pylib - ./cassandra-cqlsh-tests.sh .. + cd /tmp/cassandra/ + ./pylib/cassandra-cqlsh-tests.sh $(pwd) no_output_timeout: 15m - store_test_results: path: /tmp/cassandra/pylib @@ -7176,6 +8253,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7240,7 +8319,7 @@ jobs: - run: name: Run dtests (j11_with_vnodes) no_output_timeout: 15m - command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nset -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\n" + command: "echo \"cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\"\ncat /tmp/split_dtest_tests_j11_with_vnodes_final.txt\n\nsource ~/env3.6/bin/activate\nexport PATH=$JAVA_HOME/bin:$PATH\nif [ -n '' ]; then\n export \nfi\n\njava -version\ncd ~/cassandra-dtest\nmkdir -p /tmp/dtest\n\necho \"env: $(env)\"\necho \"** done env\"\nmkdir -p /tmp/results/dtests\n# we need the \"set -o pipefail\" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee\nexport SPLIT_TESTS=`cat /tmp/split_dtest_tests_j11_with_vnodes_final.txt`\nif [ ! -z \"$SPLIT_TESTS\" ]; then\n set -o pipefail && cd ~/cassandra-dtest && pytest --use-vnodes --num-tokens=16 --skip-resource-intensive-tests --log-level=\"DEBUG\" --junit-xml=/tmp/results/dtests/pytest_result_j11_with_vnodes.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir $SPLIT_TESTS 2>&1 | tee /tmp/dtest/stdout.txt\nelse\n echo \"Tune your parallelism, there are more containers than test classes. Nothing to do in this container\"\n (exit 1)\nfi\n" - store_test_results: path: /tmp/results - store_artifacts: @@ -7282,6 +8361,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7372,6 +8453,142 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 + - REPEATED_UPGRADE_DTESTS: null + - REPEATED_UPGRADE_DTESTS_COUNT: 25 + - REPEATED_ANT_TEST_TARGET: testsome + - REPEATED_ANT_TEST_CLASS: null + - REPEATED_ANT_TEST_METHODS: null + - REPEATED_ANT_TEST_VNODES: false + - REPEATED_ANT_TEST_COUNT: 500 + - JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - JDK_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + j8_dtests_large_vnode_repeat: + docker: + - image: apache/cassandra-testing-ubuntu2004-java11-w-dependencies:latest + resource_class: large + working_directory: ~/ + shell: /bin/bash -eo pipefail -l + parallelism: 25 + steps: + - attach_workspace: + at: /home/cassandra + - run: + name: Clone Cassandra dtest Repository (via git) + command: | + git clone --single-branch --branch $DTEST_BRANCH --depth 1 $DTEST_REPO ~/cassandra-dtest + - run: + name: Configure virtualenv and python Dependencies + command: | + # note, this should be super quick as all dependencies should be pre-installed in the docker image + # if additional dependencies were added to requirmeents.txt and the docker image hasn't been updated + # we'd have to install it here at runtime -- which will make things slow, so do yourself a favor and + # rebuild the docker image! (it automatically pulls the latest requirements.txt on build) + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + pip3 install --exists-action w --upgrade -r ~/cassandra-dtest/requirements.txt + pip3 uninstall -y cqlsh + pip3 freeze + - run: + name: Run repeated Python DTests + no_output_timeout: 15m + command: | + if [ "${REPEATED_LARGE_DTESTS}" == "" ]; then + echo "Repeated dtest name hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" == "" ]; then + echo "Repeated dtest count hasn't been defined, exiting without running any test" + elif [ "${REPEATED_LARGE_DTESTS_COUNT}" -le 0 ]; then + echo "Repeated dtest count is lesser or equals than zero, exiting without running any test" + else + + # Calculate the number of test iterations to be run by the current parallel runner. + # Since we are running the same test multiple times there is no need to use `circleci tests split`. + count=$((${REPEATED_LARGE_DTESTS_COUNT} / CIRCLE_NODE_TOTAL)) + if (($CIRCLE_NODE_INDEX < (${REPEATED_LARGE_DTESTS_COUNT} % CIRCLE_NODE_TOTAL))); then + count=$((count+1)) + fi + + if (($count <= 0)); then + echo "No tests to run in this runner" + else + echo "Running ${REPEATED_LARGE_DTESTS} $count times" + + source ~/env3.6/bin/activate + export PATH=$JAVA_HOME/bin:$PATH + + java -version + cd ~/cassandra-dtest + mkdir -p /tmp/dtest + + echo "env: $(env)" + echo "** done env" + mkdir -p /tmp/results/dtests + + tests_arg=$(echo ${REPEATED_LARGE_DTESTS} | sed -e "s/,/ /g") + + stop_on_failure_arg="" + if ${REPEATED_TESTS_STOP_ON_FAILURE}; then + stop_on_failure_arg="-x" + fi + + vnodes_args="" + if true; then + vnodes_args="--use-vnodes --num-tokens=16" + fi + + upgrade_arg="" + if false; then + upgrade_arg="--execute-upgrade-tests --upgrade-target-version-only --upgrade-version-selection all" + fi + + # we need the "set -o pipefail" here so that the exit code that circleci will actually use is from pytest and not the exit code from tee + set -o pipefail && cd ~/cassandra-dtest && pytest $vnodes_args --count=$count $stop_on_failure_arg $upgrade_arg --log-cli-level=DEBUG --junit-xml=/tmp/results/dtests/pytest_result.xml -s --cassandra-dir=/home/cassandra/cassandra --keep-test-dir --only-resource-intensive-tests --force-resource-intensive-tests $tests_arg | tee /tmp/dtest/stdout.txt + fi + fi + - store_test_results: + path: /tmp/results + - store_artifacts: + path: /tmp/dtest + destination: dtest + - store_artifacts: + path: ~/cassandra-dtest/logs + destination: dtest_logs + environment: + - ANT_HOME: /usr/share/ant + - JAVA11_HOME: /usr/lib/jvm/java-11-openjdk-amd64 + - JAVA8_HOME: /usr/lib/jvm/java-8-openjdk-amd64 + - LANG: en_US.UTF-8 + - KEEP_TEST_DIR: true + - DEFAULT_DIR: /home/cassandra/cassandra-dtest + - PYTHONIOENCODING: utf-8 + - PYTHONUNBUFFERED: true + - CASS_DRIVER_NO_EXTENSIONS: true + - CASS_DRIVER_NO_CYTHON: true + - CASSANDRA_SKIP_SYNC: true + - DTEST_REPO: https://github.com/apache/cassandra-dtest.git + - DTEST_BRANCH: trunk + - CCM_MAX_HEAP_SIZE: 1024M + - CCM_HEAP_NEWSIZE: 256M + - REPEATED_TESTS_STOP_ON_FAILURE: false + - REPEATED_UTESTS: null + - REPEATED_UTESTS_COUNT: 500 + - REPEATED_UTESTS_FQLTOOL: null + - REPEATED_UTESTS_FQLTOOL_COUNT: 500 + - REPEATED_UTESTS_LONG: null + - REPEATED_UTESTS_LONG_COUNT: 100 + - REPEATED_UTESTS_STRESS: null + - REPEATED_UTESTS_STRESS_COUNT: 500 + - REPEATED_SIMULATOR_DTESTS: null + - REPEATED_SIMULATOR_DTESTS_COUNT: 500 + - REPEATED_JVM_DTESTS: null + - REPEATED_JVM_DTESTS_COUNT: 500 + - REPEATED_JVM_UPGRADE_DTESTS: null + - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 + - REPEATED_DTESTS: null + - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7461,6 +8678,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7565,6 +8784,8 @@ jobs: - REPEATED_JVM_UPGRADE_DTESTS_COUNT: 500 - REPEATED_DTESTS: null - REPEATED_DTESTS_COUNT: 500 + - REPEATED_LARGE_DTESTS: null + - REPEATED_LARGE_DTESTS_COUNT: 100 - REPEATED_UPGRADE_DTESTS: null - REPEATED_UPGRADE_DTESTS_COUNT: 25 - REPEATED_ANT_TEST_TARGET: testsome @@ -7601,6 +8822,18 @@ workflows: requires: - start_j8_jvm_dtests_vnode - j8_build + - start_j11_jvm_dtests: + type: approval + - j11_jvm_dtests: + requires: + - start_j11_jvm_dtests + - j8_build + - start_j11_jvm_dtests_vnode: + type: approval + - j11_jvm_dtests_vnode: + requires: + - start_j11_jvm_dtests_vnode + - j8_build - start_j8_simulator_dtests: type: approval - j8_simulator_dtests: @@ -7613,6 +8846,24 @@ workflows: requires: - start_j8_cqlshlib_tests - j8_build + - start_j8_cqlshlib_cython_tests: + type: approval + - j8_cqlshlib_cython_tests: + requires: + - start_j8_cqlshlib_cython_tests + - j8_build + - start_j11_cqlshlib_tests: + type: approval + - j11_cqlshlib_tests: + requires: + - start_j11_cqlshlib_tests + - j8_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j8_build - start_j11_unit_tests: type: approval - j11_unit_tests: @@ -7739,6 +8990,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7820,9 +9095,24 @@ workflows: - j8_jvm_dtests_vnode: requires: - j8_build + - j11_jvm_dtests: + requires: + - j8_build + - j11_jvm_dtests_vnode: + requires: + - j8_build - j8_cqlshlib_tests: requires: - j8_build + - j8_cqlshlib_cython_tests: + requires: + - j8_build + - j11_cqlshlib_tests: + requires: + - j8_build + - j11_cqlshlib_cython_tests: + requires: + - j8_build - j11_unit_tests: requires: - j8_build @@ -7918,6 +9208,30 @@ workflows: requires: - start_j11_dtests_offheap - j8_build + - start_j8_dtests_large: + type: approval + - j8_dtests_large: + requires: + - start_j8_dtests_large + - j8_build + - start_j8_dtests_large_vnode: + type: approval + - j8_dtests_large_vnode: + requires: + - start_j8_dtests_large_vnode + - j8_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j8_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j8_build - start_upgrade_dtests: type: approval - j8_upgrade_dtests: @@ -7999,6 +9313,12 @@ workflows: requires: - start_j11_cqlshlib_tests - j11_build + - start_j11_cqlshlib_cython_tests: + type: approval + - j11_cqlshlib_cython_tests: + requires: + - start_j11_cqlshlib_cython_tests + - j11_build - start_j11_dtests: type: approval - j11_dtests: @@ -8017,6 +9337,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - start_j11_cqlsh_tests: type: approval - j11_cqlsh_dtests_py3: @@ -8100,7 +9432,7 @@ workflows: - j11_cqlshlib_tests: requires: - j11_build - - j11_cqlshlib_tests: + - j11_cqlshlib_cython_tests: requires: - j11_build - j11_dtests: @@ -8115,6 +9447,18 @@ workflows: requires: - start_j11_dtests_offheap - j11_build + - start_j11_dtests_large: + type: approval + - j11_dtests_large: + requires: + - start_j11_dtests_large + - j11_build + - start_j11_dtests_large_vnode: + type: approval + - j11_dtests_large_vnode: + requires: + - start_j11_dtests_large_vnode + - j11_build - j11_cqlsh_dtests_py3: requires: - j11_build diff --git a/.circleci/generate.sh b/.circleci/generate.sh index e083b052f9..384709489b 100755 --- a/.circleci/generate.sh +++ b/.circleci/generate.sh @@ -56,6 +56,8 @@ print_help() echo " -e REPEATED_JVM_UPGRADE_DTESTS_COUNT=500" echo " -e REPEATED_DTESTS=cdc_test.py cqlsh_tests/test_cqlsh.py::TestCqlshSmoke" echo " -e REPEATED_DTESTS_COUNT=500" + echo " -e REPEATED_LARGE_DTESTS=consistency_test.py::TestAvailability::test_network_topology_strategy" + echo " -e REPEATED_LARGE_DTESTS=100" echo " -e REPEATED_UPGRADE_DTESTS=upgrade_tests/cql_tests.py upgrade_tests/paging_test.py" echo " -e REPEATED_UPGRADE_DTESTS_COUNT=25" echo " -e REPEATED_ANT_TEST_TARGET=testsome" @@ -87,7 +89,7 @@ while getopts "e:almhf" opt; do ;; h ) highres=true ;; - e ) if (!($has_env_vars)); then + e ) if (! ($has_env_vars)); then env_vars="$OPTARG" else env_vars="$env_vars|$OPTARG" @@ -128,6 +130,8 @@ if $has_env_vars && $check_env_vars; then [ "$key" != "REPEATED_JVM_UPGRADE_DTESTS_COUNT" ] && [ "$key" != "REPEATED_DTESTS" ] && [ "$key" != "REPEATED_DTESTS_COUNT" ] && + [ "$key" != "REPEATED_LARGE_DTESTS" ] && + [ "$key" != "REPEATED_LARGE_DTESTS_COUNT" ] && [ "$key" != "REPEATED_UPGRADE_DTESTS" ] && [ "$key" != "REPEATED_UPGRADE_DTESTS_COUNT" ] && [ "$key" != "REPEATED_ANT_TEST_TARGET" ] && @@ -187,13 +191,13 @@ elif $all; then # copy lower into config.yml to make sure this gets updated cp $BASEDIR/config.yml.LOWRES $BASEDIR/config.yml -elif (!($has_env_vars)); then +elif (! ($has_env_vars)); then print_help exit 0 fi # add new or modified tests to the sets of tests to be repeated -if (!($all)); then +if (! ($all)); then add_diff_tests () { dir="${BASEDIR}/../${2}" @@ -305,6 +309,12 @@ delete_repeated_jobs() delete_job "$1" "j11_dtests_vnode_repeat" delete_job "$1" "j11_dtests_offheap_repeat" fi + if (! (echo "$env_vars" | grep -q "REPEATED_LARGE_DTESTS=")); then + delete_job "$1" "j8_dtests_large_repeat" + delete_job "$1" "j8_dtests_large_vnode_repeat" + delete_job "$1" "j11_dtests_large_repeat" + delete_job "$1" "j11_dtests_large_vnode_repeat" + fi if (! (echo "$env_vars" | grep -q "REPEATED_UPGRADE_DTESTS=")); then delete_job "$1" "j8_upgrade_dtests_repeat" fi diff --git a/.circleci/readme.md b/.circleci/readme.md index 952e964c06..2e3f55e9cb 100644 --- a/.circleci/readme.md +++ b/.circleci/readme.md @@ -78,6 +78,7 @@ generate.sh -m \ -e REPEATED_JVM_DTESTS_COUNT=500 \ -e REPEATED_JVM_UPGRADE_DTESTS_COUNT=500 \ -e REPEATED_DTESTS_COUNT=500 \ + -e REPEATED_LARGE_DTESTS_COUNT=100 \ -e REPEATED_UPGRADE_DTESTS_COUNT=25 \ -e REPEATED_ANT_TEST_COUNT=500 ``` @@ -95,6 +96,7 @@ generate.sh -m \ -e REPEATED_UTESTS_STRESS=org.apache.cassandra.stress.generate.DistributionGaussianTest \ -e REPEATED_SIMULATOR_DTESTS=org.apache.cassandra.simulator.test.TrivialSimulationTest \ -e REPEATED_DTESTS=cql_test.py,consistency_test.py::TestAvailability::test_simple_strategy \ + -e REPEATED_LARGE_DTESTS=consistency_test.py::TestAvailability::test_network_topology_strategy \ -e REPEATED_JVM_DTESTS=org.apache.cassandra.distributed.test.PagingTest#testPaging \ -e REPEATED_UPGRADE_DTESTS=upgrade_tests/cql_tests.py \ -e REPEATED_JVM_UPGRADE_DTESTS=org.apache.cassandra.distributed.upgrade.GroupByTest @@ -125,6 +127,8 @@ generate.sh -m \ -e REPEATED_SIMULATOR_DTESTS_COUNT=500 \ -e REPEATED_DTESTS=cql_test.py,consistency_test.py::TestAvailability::test_simple_strategy \ -e REPEATED_DTESTS_COUNT=500 \ + -e REPEATED_LARGE_DTESTS=consistency_test.py,materialized_views_test.py \ + -e REPEATED_LARGE_DTESTS=100 \ -e REPEATED_JVM_DTESTS=org.apache.cassandra.distributed.test.PagingTest#testPaging \ -e REPEATED_JVM_DTESTS_COUNT=500 \ -e REPEATED_UPGRADE_DTESTS=upgrade_tests/cql_tests.py \ diff --git a/pylib/cassandra-cqlsh-tests.sh b/pylib/cassandra-cqlsh-tests.sh index 9a5df9f281..951f69a61a 100755 --- a/pylib/cassandra-cqlsh-tests.sh +++ b/pylib/cassandra-cqlsh-tests.sh @@ -39,7 +39,7 @@ export CASS_DRIVER_NO_CYTHON=true export CCM_MAX_HEAP_SIZE="2048M" export CCM_HEAP_NEWSIZE="200M" export CCM_CONFIG_DIR=${WORKSPACE}/.ccm -export NUM_TOKENS="32" +export NUM_TOKENS="16" export CASSANDRA_DIR=${WORKSPACE} export TESTSUITE_NAME="cqlshlib.${PYTHON_VERSION}"