diff options
-rw-r--r-- | jstests/sharding/set_index_commit_quorum_through_mongos.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/jstests/sharding/set_index_commit_quorum_through_mongos.js b/jstests/sharding/set_index_commit_quorum_through_mongos.js index fabcc3e161b..2326db57005 100644 --- a/jstests/sharding/set_index_commit_quorum_through_mongos.js +++ b/jstests/sharding/set_index_commit_quorum_through_mongos.js @@ -7,6 +7,7 @@ "use strict"; load("jstests/libs/fail_point_util.js"); load('jstests/libs/parallelTester.js'); +load('jstests/noPassthrough/libs/index_build.js'); const st = new ShardingTest({shards: 2, mongos: 1, rs: {nodes: 2}}); const dbName = "testDB"; @@ -14,6 +15,14 @@ const collName = "coll"; const mongosDB = st.s0.getDB(dbName); const shard0 = st.shard0.rs.getPrimary(); +if (!(IndexBuildTest.supportsTwoPhaseIndexBuild(shard0) && + IndexBuildTest.indexBuildCommitQuorumEnabled(shard0))) { + jsTestLog( + 'Skipping test because two phase index build and index build commit quorum are not supported.'); + st.stop(); + return; +} + const generateCreateIndexThread = (host, dbName, collName) => { return new Thread(function(host, dbName, collName) { const mongos = new Mongo(host); |