diff options
author | Pavi Vetriselvan <pavithra.vetriselvan@mongodb.com> | 2020-08-26 13:45:37 -0400 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-09-03 19:16:09 +0000 |
commit | b1920ea0a48a86bcd99eb5273ccbf12c008e4ed0 (patch) | |
tree | af34399c0e3acb0cce0cae747000a95e4ddd0929 /src/mongo/client | |
parent | 8e3271aaf22106853bf36429cfcee39ed6055f35 (diff) | |
download | mongo-b1920ea0a48a86bcd99eb5273ccbf12c008e4ed0.tar.gz |
SERVER-50409 Change NotMasterNoSlaveOk error name to NotPrimaryNoSecondaryOk
Diffstat (limited to 'src/mongo/client')
-rw-r--r-- | src/mongo/client/dbclient_rs.cpp | 2 | ||||
-rw-r--r-- | src/mongo/client/streamable_replica_set_monitor_error_handler_test.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/client/dbclient_rs.cpp b/src/mongo/client/dbclient_rs.cpp index 0f3df602910..7aaa15adfe8 100644 --- a/src/mongo/client/dbclient_rs.cpp +++ b/src/mongo/client/dbclient_rs.cpp @@ -1006,7 +1006,7 @@ void DBClientReplicaSet::checkResponse(const std::vector<BSONObj>& batch, if (networkError || (hasErrField(dataObj) && !dataObj["code"].eoo() && - dataObj["code"].Int() == ErrorCodes::NotMasterNoSlaveOk)) { + dataObj["code"].Int() == ErrorCodes::NotPrimaryNoSecondaryOk)) { if (_lazyState._lastClient == _master.get()) { isntMaster(); } diff --git a/src/mongo/client/streamable_replica_set_monitor_error_handler_test.cpp b/src/mongo/client/streamable_replica_set_monitor_error_handler_test.cpp index 497d3d04f2a..9856d9f35a4 100644 --- a/src/mongo/client/streamable_replica_set_monitor_error_handler_test.cpp +++ b/src/mongo/client/streamable_replica_set_monitor_error_handler_test.cpp @@ -112,7 +112,7 @@ public: ErrorCodes::PrimarySteppedDown, ErrorCodes::ShutdownInProgress, ErrorCodes::NotWritablePrimary, - ErrorCodes::NotMasterNoSlaveOk}; + ErrorCodes::NotPrimaryNoSecondaryOk}; inline static const std::string kSetName = "setName"; inline static const HostAndPort kHost = HostAndPort("foobar:123"); |