diff options
author | Amirsaman Memaripour <amirsaman.memaripour@mongodb.com> | 2020-06-08 14:34:05 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-06-10 13:27:50 +0000 |
commit | 87de9a0cb1e898d7b49c04558e60c40103ee1d8f (patch) | |
tree | d44229db06bed5b36a1d270a0521ea80d6f1fd60 /buildscripts | |
parent | bacc717789965d83d5253a4591c5f3171c741c39 (diff) | |
download | mongo-87de9a0cb1e898d7b49c04558e60c40103ee1d8f.tar.gz |
SERVER-46726 Make multiversion tests work with the new parameter
This patch addresses issues concerning running mongos in multiversion tests.
Diffstat (limited to 'buildscripts')
4 files changed, 14 insertions, 14 deletions
diff --git a/buildscripts/resmokelib/core/programs.py b/buildscripts/resmokelib/core/programs.py index 42783bc8221..ab117fbc87d 100644 --- a/buildscripts/resmokelib/core/programs.py +++ b/buildscripts/resmokelib/core/programs.py @@ -10,6 +10,7 @@ import stat import sys from buildscripts.resmokelib.multiversionconstants import LAST_STABLE_MONGOD_BINARY +from buildscripts.resmokelib.multiversionconstants import LAST_STABLE_MONGOS_BINARY from . import jasper_process from . import process from .. import config @@ -203,7 +204,7 @@ def mongod_program( # pylint: disable=too-many-branches,too-many-statements "mode": "alwaysOn", "data": {"numTickets": config.FLOW_CONTROL_TICKETS} } - # TODO(SERVER-46726): Only keep the else block once SERVER-46726 is backported to v4.4 + # TODO(SERVER-48645): Only keep the else block once v4.4 is not longer the last stable version if executable == LAST_STABLE_MONGOD_BINARY: suite_set_parameters.setdefault("enableTestCommands", True) else: @@ -286,8 +287,8 @@ def mongos_program(logger, executable=None, process_kwargs=None, **kwargs): if "logComponentVerbosity" not in suite_set_parameters: suite_set_parameters["logComponentVerbosity"] = default_mongos_log_component_verbosity() - # TODO(SERVER-46726): Only keep the else block once SERVER-46726 is backported to v4.4 - if executable == LAST_STABLE_MONGOD_BINARY: + # TODO(SERVER-48645): Only keep the else block once v4.4 is not longer the last stable version + if executable == LAST_STABLE_MONGOS_BINARY: suite_set_parameters.setdefault("enableTestCommands", True) else: _add_testing_set_parameters(suite_set_parameters) diff --git a/buildscripts/resmokelib/multiversionconstants.py b/buildscripts/resmokelib/multiversionconstants.py index cae07ff7a64..3d0bf83debc 100644 --- a/buildscripts/resmokelib/multiversionconstants.py +++ b/buildscripts/resmokelib/multiversionconstants.py @@ -1,9 +1,10 @@ """FCV and Server binary version constants used for multiversion testing.""" -LAST_STABLE_MONGO_BINARY = "mongo-4.4" -LAST_STABLE_MONGOD_BINARY = "mongod-4.4" -REQUIRES_FCV_TAG = "requires_fcv_46" - +LAST_STABLE_BIN_VERSION = "4.4" LAST_STABLE_FCV = "4.4" LATEST_FCV = "4.6" -LAST_STABLE_BIN_VERSION = "4.4" + +LAST_STABLE_MONGO_BINARY = "mongo-" + LAST_STABLE_BIN_VERSION +LAST_STABLE_MONGOD_BINARY = "mongod-" + LAST_STABLE_BIN_VERSION +LAST_STABLE_MONGOS_BINARY = "mongos-" + LAST_STABLE_BIN_VERSION +REQUIRES_FCV_TAG = "requires_fcv_46" diff --git a/buildscripts/resmokelib/testing/fixtures/replicaset.py b/buildscripts/resmokelib/testing/fixtures/replicaset.py index dd57eca1074..34564e62df7 100644 --- a/buildscripts/resmokelib/testing/fixtures/replicaset.py +++ b/buildscripts/resmokelib/testing/fixtures/replicaset.py @@ -14,6 +14,7 @@ from . import standalone from ... import config from ... import errors from ... import utils +from ...multiversionconstants import LAST_STABLE_MONGOD_BINARY class ReplicaSetFixture(interface.ReplFixture): # pylint: disable=too-many-instance-attributes @@ -59,13 +60,11 @@ class ReplicaSetFixture(interface.ReplFixture): # pylint: disable=too-many-inst latest_mongod = mongod_executable # The last-stable binary is currently expected to live in '/data/multiversion', which is # part of the PATH. - last_stable_mongod = config.DEFAULT_MONGOD_EXECUTABLE + "-" \ - + ReplicaSetFixture._LAST_STABLE_BIN_VERSION is_config_svr = "configsvr" in self.replset_config_options and self.replset_config_options[ "configsvr"] if not is_config_svr: self.mixed_bin_versions = [ - latest_mongod if (x == "new") else last_stable_mongod + latest_mongod if (x == "new") else LAST_STABLE_MONGOD_BINARY for x in self.mixed_bin_versions ] else: diff --git a/buildscripts/resmokelib/testing/fixtures/shardedcluster.py b/buildscripts/resmokelib/testing/fixtures/shardedcluster.py index 40fadef17ad..1b3e6628ea7 100644 --- a/buildscripts/resmokelib/testing/fixtures/shardedcluster.py +++ b/buildscripts/resmokelib/testing/fixtures/shardedcluster.py @@ -14,6 +14,7 @@ from ... import core from ... import errors from ... import utils from ...utils import registry +from ...multiversionconstants import LAST_STABLE_MONGOS_BINARY class ShardedClusterFixture(interface.Fixture): # pylint: disable=too-many-instance-attributes @@ -336,9 +337,7 @@ class ShardedClusterFixture(interface.Fixture): # pylint: disable=too-many-inst # The last-stable binary is currently expected to live in '/data/multiversion', which is # part of the PATH. - last_stable_executable = config.DEFAULT_MONGOS_EXECUTABLE + "-" \ - + ShardedClusterFixture._LAST_STABLE_BIN_VERSION - mongos_executable = self.mongos_executable if self.mixed_bin_versions is None else last_stable_executable + mongos_executable = self.mongos_executable if self.mixed_bin_versions is None else LAST_STABLE_MONGOS_BINARY return _MongoSFixture(mongos_logger, self.job_num, dbpath_prefix=self._dbpath_prefix, mongos_executable=mongos_executable, mongos_options=mongos_options) |