[SERVER-31513] Enumerate the possible featureCompatibilityVersion states in one atomic variable Created: 11/Oct/17  Updated: 30/Oct/23  Resolved: 16/Oct/17

Status: Closed
Project: Core Server
Component/s: Storage
Affects Version/s: None
Fix Version/s: 3.6.0-rc1

Type: Improvement Priority: Major - P3
Reporter: Louis Williams Assignee: Backlog - Storage Execution Team
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Storage Execution
Backwards Compatibility: Fully Compatible
Sprint: Storage 2017-10-23
Participants:

 Description   

There are two separate atomic variables for the version and targetVersion fields in serverGlobalParams. There is a potential for a races when reading the actual state through isFullyUpgradedTo36() and similar accessors, which must read both variables separately.

The ServerGlobalParams::FeatureCompatiblity::Version enum should enumerate the following states in one atomic variable. Getters and setters should be appropriately modified.

FeatureCompatibility::Version fCV version fCV targetVersion notes
kUnset (unset) (unset) a safe getter should return "3.4"
k34 3.4 (unset)
kUpgradingTo36 3.4 3.6
k36 3.6 (unset)
kDowngradingTo34 3.4 3.4


 Comments   
Comment by Githook User [ 16/Oct/17 ]

Author:

{'email': 'louis.williams@mongodb.com', 'name': 'Louis Williams', 'username': 'louiswilliams'}

Message: SERVER-30242 SERVER-31513 SERVER-31235 Make method to determine if fCV has been initialized in memory. Make fCV state one atomic variable. Initialize fCV on arbiters once a primary is elected.
Branch: master
https://github.com/mongodb/mongo/commit/203ff7c010d1d4fcbe291852f70fb9d967a171cc

Generated at Thu Feb 08 04:27:18 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.