diff options
author | Gregory Noma <gregory.noma@gmail.com> | 2020-09-02 15:15:39 -0400 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-09-02 21:07:38 +0000 |
commit | 30e0f2a2b33a9b87259ac4c8a9e19518e2b8e1a3 (patch) | |
tree | ccceafcbe2ae41c1a826bc5a238be538881f0367 /jstests | |
parent | a8bf9e88b3cd2c0036b3ae3e484dbbc933fc4614 (diff) | |
download | mongo-30e0f2a2b33a9b87259ac4c8a9e19518e2b8e1a3.tar.gz |
SERVER-49774 Enable rollback testing for resumable index builds in the collection scan phase
Diffstat (limited to 'jstests')
-rw-r--r-- | jstests/replsets/rollback_resumable_index_build_collection_scan_phase.js | 24 |
1 files changed, 9 insertions, 15 deletions
diff --git a/jstests/replsets/rollback_resumable_index_build_collection_scan_phase.js b/jstests/replsets/rollback_resumable_index_build_collection_scan_phase.js index 42dd72869e8..c044d015bc1 100644 --- a/jstests/replsets/rollback_resumable_index_build_collection_scan_phase.js +++ b/jstests/replsets/rollback_resumable_index_build_collection_scan_phase.js @@ -21,33 +21,27 @@ const coll = rollbackTest.getPrimary().getDB(dbName).getCollection(jsTestName()) assert.commandWorked(coll.insert([{a: 1}, {a: 2}, {a: 3}, {a: 4}, {a: 5}])); -// TODO (SERVER-49774): Enable these test cases once resumable index builds are resilient to the -// node going into rollback during the collection scan phase. -if (true) { - rollbackTest.stop(); - return; -} - -// Rollback to earlier in the collection scan phase. +// Rollback to before the index begins to be built. RollbackResumableIndexBuildTest.run(rollbackTest, dbName, coll.getName(), {a: 1}, rollbackStartFailPointName, - {fieldsToMatch: {a: 4}}, - "hangIndexBuildDuringCollectionScanPhaseAfterInsertion", {fieldsToMatch: {a: 2}}, + "hangAfterSettingUpIndexBuildUnlocked", + {}, insertsToBeRolledBack); -// Rollback to before the index begins to be built. +// Rollback to earlier in the collection scan phase. RollbackResumableIndexBuildTest.run(rollbackTest, dbName, coll.getName(), {a: 1}, rollbackStartFailPointName, - {fieldsToMatch: {a: 2}}, - "hangAfterSettingUpIndexBuildUnlocked", - {}); + {iteration: 4}, + "hangIndexBuildDuringCollectionScanPhaseAfterInsertion", + {iteration: 2}, + insertsToBeRolledBack); rollbackTest.stop(); -})(); +})();
\ No newline at end of file |