diff options
author | Vesselina Ratcheva <vesselina.ratcheva@10gen.com> | 2022-04-04 17:53:07 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-04-04 18:25:30 +0000 |
commit | 6abfb1f99e65c451b233bce7e1b941d74669a7b5 (patch) | |
tree | f0607dfb7869259e6eb99e39770fccac6ec652eb /buildscripts | |
parent | 12fc3ef71b375ce012ad639ee1adfed555819503 (diff) | |
download | mongo-6abfb1f99e65c451b233bce7e1b941d74669a7b5.tar.gz |
SERVER-60209 Add option of persisting old multiversion constants after upgrade
Diffstat (limited to 'buildscripts')
-rw-r--r-- | buildscripts/resmokelib/multiversionconstants.py | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/buildscripts/resmokelib/multiversionconstants.py b/buildscripts/resmokelib/multiversionconstants.py index 6055e771c24..0ff3b42b56f 100644 --- a/buildscripts/resmokelib/multiversionconstants.py +++ b/buildscripts/resmokelib/multiversionconstants.py @@ -111,6 +111,7 @@ def calculate_fcv_constants(): fcvs = list(map(Version, fcvs)) lts = releases_yml['longTermSupportReleases'] lts = list(map(Version, lts)) + lower_bound_override = releases_yml.get('generateFCVLowerBoundOverride') mongo_version_yml_file.close() releases_yml_file.close() @@ -121,8 +122,13 @@ def calculate_fcv_constants(): # Highest LTS release less than latest. last_lts = lts[bisect_left(lts, latest) - 1] - # All FCVs greater than last LTS, up to latest. - requires_fcv_tag_list = fcvs[bisect_right(fcvs, last_lts):bisect_right(fcvs, latest)] + # Normally, this list includes all FCVs greater than last LTS, up to latest. + # However, if we have 'generateFCVLowerBoundOverride' set in releases.yml, we will + # extend the lower bound to also include the prevous value of lastLTS. + lts_cutoff = last_lts + if lower_bound_override is not None: + lts_cutoff = Version(lower_bound_override) + requires_fcv_tag_list = fcvs[bisect_right(fcvs, lts_cutoff):bisect_right(fcvs, latest)] # All FCVs less than latest. fcvs_less_than_latest = fcvs[:bisect_left(fcvs, latest)] @@ -165,7 +171,7 @@ LAST_LTS_MONGOS_BINARY = "mongos-" + LAST_LTS_BIN_VERSION REQUIRES_FCV_TAG_LATEST = tag_str(fcv_constants.latest) -# Generate tags for all FCVS in (lastLTS, latest]. +# Generate tags for all FCVS in (lastLTS, latest], or (lowerBoundOverride, latest] if requested. # All multiversion tests should be run with these tags excluded. REQUIRES_FCV_TAG = ",".join([tag_str(fcv) for fcv in fcv_constants.requires_fcv_tag_list]) |