summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Gottlieb <daniel.gottlieb@mongodb.com>2019-02-07 14:48:46 -0500
committerDaniel Gottlieb <daniel.gottlieb@mongodb.com>2019-02-11 09:41:53 -0500
commit646ff4b0ab9669f2260c6a017bbf3d45d1e48e6a (patch)
tree0f517c7e8c85c8a5b700525d647e2be3988805b9 /src
parent0252c9ee56371663b05e707d69bceaf29de6645f (diff)
downloadmongo-646ff4b0ab9669f2260c6a017bbf3d45d1e48e6a.tar.gz
SERVER-35651: Don't downgrade data files when a 4.2 binary running as an arbiter is shut down.
To downgrade binaries for an arbiter, the user must delete the dbpath.
Diffstat (limited to 'src')
-rw-r--r--src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp b/src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp
index 3353b835cd9..a1595730c5b 100644
--- a/src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp
+++ b/src/mongo/db/storage/wiredtiger/wiredtiger_kv_engine.cpp
@@ -124,7 +124,10 @@ bool WiredTigerFileVersion::shouldDowngrade(bool readOnly,
const auto replCoord = repl::ReplicationCoordinator::get(getGlobalServiceContext());
const auto memberState = replCoord->getMemberState();
if (memberState.arbiter()) {
- return true;
+ // SERVER-35361: Arbiters will no longer downgrade their data files. To downgrade
+ // binaries, the user must delete the dbpath. It's not particularly expensive for a
+ // replica set to re-initialize an arbiter that comes online.
+ return false;
}
if (!serverGlobalParams.featureCompatibility.isVersionInitialized()) {