diff options
author | William Schultz <william.schultz@mongodb.com> | 2017-04-06 16:42:52 -0400 |
---|---|---|
committer | William Schultz <william.schultz@mongodb.com> | 2017-05-03 17:04:04 -0400 |
commit | b54a4c655b2f35ebaae739f959e6e5b7d48f5f04 (patch) | |
tree | b2b07c5a276ec542853d791a345501a19589035b /etc | |
parent | fa2dcc33303dd6a2080c108e121da6984d08a9d6 (diff) | |
download | mongo-b54a4c655b2f35ebaae739f959e6e5b7d48f5f04.tar.gz |
SERVER-28222 Add Jepsen read-concern-majority test to evergreen
Diffstat (limited to 'etc')
-rw-r--r-- | etc/evergreen.yml | 56 |
1 files changed, 48 insertions, 8 deletions
diff --git a/etc/evergreen.yml b/etc/evergreen.yml index 47cd93cd7d9..d0d8b1d9b20 100644 --- a/etc/evergreen.yml +++ b/etc/evergreen.yml @@ -624,27 +624,30 @@ functions: end_time=$(date +%s) elapsed_secs=$((end_time-start_time)) # Since we cannot use PIPESTATUS to get the exit code from the "lein run ..." pipe in dash shell, - # we will check the output for success, failure or setup error. + # we will check the output for success, failure or setup error. Note that 'grep' returns with exit code + # 0 if it finds a match, and exit code 1 if no match is found. grep -q "Everything looks good" jepsen_${task_name}_${execution}.log - exit_code=$? - if [ $exit_code -eq 0 ]; then + grep_exit_code=$? + if [ $grep_exit_code -eq 0 ]; then status='"pass"' failures=0 + final_exit_code=0 else grep -q "Analysis invalid" jepsen_${task_name}_${execution}.log - exit_code=$? - if [ $exit_code -eq 0 ]; then + grep_exit_code=$? + if [ $grep_exit_code -eq 0 ]; then status='"fail"' failures=1 + final_exit_code=1 else # If the failure is due to setup, then this is considered a system failure. - echo $exit_code > jepsen_system_failure_${task_name}_${execution} + echo $grep_exit_code > jepsen_system_failure_${task_name}_${execution} exit 0 fi fi # Create report.json - echo "{\"failures\": $failures, \"results\": [{\"status\": $status, \"exit_code\": $exit_code, \"test_file\": \"${task_name}\", \"start\": $start_time, \"end\": $end_time, \"elapsed\": $elapsed_secs}]}" > ../../report.json - exit $exit_code + echo "{\"failures\": $failures, \"results\": [{\"status\": $status, \"exit_code\": $exit_code, \"test_file\": \"${task_name}\", \"start\": $start_time, \"end\": $end_time, \"elapsed\": $elapsed_secs}]}" > ../report.json + exit $final_exit_code - command: shell.exec params: working_dir: src/jepsen-mongodb @@ -1488,6 +1491,31 @@ tasks: jepsen_storage_engine: --storage-engine wiredTiger jepsen_test_name: set +- <<: *run_jepsen_template + # We only run this test on wiredTiger since MMAPv1 doesn't support majority read concern. + name: jepsen_read-concern-majority_WT + commands: + - func: "do setup" + - func: "do jepsen setup" + - func: "run jepsen test" + vars: + <<: *jepsen_config_vars + jepsen_storage_engine: --storage-engine wiredTiger + jepsen_test_name: read-concern-majority + +- <<: *run_jepsen_template + # We only run this test on wiredTiger since MMAPv1 doesn't support majority read concern. + name: jepsen_read-concern-majority_w1_WT + commands: + - func: "do setup" + - func: "do jepsen setup" + - func: "run jepsen test" + vars: + <<: *jepsen_config_vars + jepsen_storage_engine: --storage-engine wiredTiger + jepsen_test_name: read-concern-majority + jepsen_write_concern: --write-concern w1 + ## jstestfuzz mmapv1 ## - <<: *jstestfuzz_template name: jstestfuzz @@ -4095,6 +4123,12 @@ buildvariants: - name: jepsen_set_linearizableRead_WT distros: - ubuntu1404-jepsen + - name: jepsen_read-concern-majority_WT + distros: + - ubuntu1404-jepsen + - name: jepsen_read-concern-majority_w1_WT + distros: + - ubuntu1404-jepsen - name: jsCore - name: jsCore_WT - name: jsCore_auth @@ -6787,6 +6821,12 @@ buildvariants: - name: jepsen_set_linearizableRead_WT distros: - ubuntu1404-jepsen + - name: jepsen_read-concern-majority_WT + distros: + - ubuntu1404-jepsen + - name: jepsen_read-concern-majority_w1_WT + distros: + - ubuntu1404-jepsen - name: jsCore - name: jsCore_auth - name: jstestfuzz |