diff options
author | Billy Donahue <billy.donahue@mongodb.com> | 2018-01-22 18:24:04 -0500 |
---|---|---|
committer | Billy Donahue <billy.donahue@mongodb.com> | 2018-01-24 13:51:39 -0500 |
commit | 90fa214a651f42185ae660091f599edf3bb422e4 (patch) | |
tree | 22aea81bc661506a7dd8f16c610ade7c0ef1e642 /src/mongo/db/s/collection_sharding_state.cpp | |
parent | bc433b50e0205dfd0a8bfb6906393d841fd8193a (diff) | |
download | mongo-90fa214a651f42185ae660091f599edf3bb422e4.tar.gz |
SERVER-32846 NamespaceString: add and remove relational operators
relops for NamespaceString
fix client sites relying on NamespaceString vs string
Diffstat (limited to 'src/mongo/db/s/collection_sharding_state.cpp')
-rw-r--r-- | src/mongo/db/s/collection_sharding_state.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/db/s/collection_sharding_state.cpp b/src/mongo/db/s/collection_sharding_state.cpp index 9b554195cd7..9b4d84756aa 100644 --- a/src/mongo/db/s/collection_sharding_state.cpp +++ b/src/mongo/db/s/collection_sharding_state.cpp @@ -320,7 +320,7 @@ void CollectionShardingState::onUpdateOp(OperationContext* opCtx, dassert(opCtx->lockState()->isCollectionLockedForMode(_nss.ns(), MODE_IX)); if (serverGlobalParams.clusterRole == ClusterRole::ShardServer) { - if (_nss == NamespaceString::kShardConfigCollectionsCollectionName) { + if (_nss.ns() == NamespaceString::kShardConfigCollectionsCollectionName) { _onConfigCollectionsUpdateOp(opCtx, query, update, updatedDoc); } @@ -348,7 +348,7 @@ void CollectionShardingState::onDeleteOp(OperationContext* opCtx, dassert(opCtx->lockState()->isCollectionLockedForMode(_nss.ns(), MODE_IX)); if (serverGlobalParams.clusterRole == ClusterRole::ShardServer) { - if (_nss == NamespaceString::kShardConfigCollectionsCollectionName) { + if (_nss.ns() == NamespaceString::kShardConfigCollectionsCollectionName) { _onConfigDeleteInvalidateCachedMetadataAndNotify(opCtx, deleteState.documentKey); } @@ -370,7 +370,7 @@ void CollectionShardingState::onDeleteOp(OperationContext* opCtx, } if (serverGlobalParams.clusterRole == ClusterRole::ConfigServer) { - if (_nss == VersionType::ConfigNS) { + if (_nss.ns() == VersionType::ConfigNS) { if (!repl::ReplicationCoordinator::get(opCtx)->getMemberState().rollback()) { uasserted(40302, "cannot delete config.version document while in --configsvr mode"); } else { @@ -407,7 +407,7 @@ void CollectionShardingState::onDropCollection(OperationContext* opCtx, } if (serverGlobalParams.clusterRole == ClusterRole::ConfigServer) { - if (_nss == VersionType::ConfigNS) { + if (_nss.ns() == VersionType::ConfigNS) { if (!repl::ReplicationCoordinator::get(opCtx)->getMemberState().rollback()) { uasserted(40303, "cannot drop config.version document while in --configsvr mode"); } else { |