summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mongo/client/sdam/topology_manager.h2
-rw-r--r--src/mongo/db/s/wait_for_majority_service.h2
-rw-r--r--src/mongo/db/storage/kv/kv_prefix.cpp2
-rw-r--r--src/mongo/s/client/shard_registry.h2
4 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/client/sdam/topology_manager.h b/src/mongo/client/sdam/topology_manager.h
index f52729b0946..292d48b6e8e 100644
--- a/src/mongo/client/sdam/topology_manager.h
+++ b/src/mongo/client/sdam/topology_manager.h
@@ -65,7 +65,7 @@ public:
const TopologyDescriptionPtr getTopologyDescription() const;
private:
- mutable mongo::Mutex _mutex = mongo::Mutex(StringData("TopologyManager"));
+ mutable mongo::Mutex _mutex = MONGO_MAKE_LATCH("TopologyManager");
const SdamConfiguration _config;
ClockSource* _clockSource;
std::shared_ptr<TopologyDescription> _topologyDescription;
diff --git a/src/mongo/db/s/wait_for_majority_service.h b/src/mongo/db/s/wait_for_majority_service.h
index 90ec771bd40..1663ce907ac 100644
--- a/src/mongo/db/s/wait_for_majority_service.h
+++ b/src/mongo/db/s/wait_for_majority_service.h
@@ -74,7 +74,7 @@ private:
*/
void _periodicallyWaitForMajority(ServiceContext* service);
- Mutex _mutex = MONGO_MAKE_LATCH("WaitForMaorityService::_mutex");
+ Mutex _mutex = MONGO_MAKE_LATCH("WaitForMajorityService::_mutex");
// Contains an ordered list of opTimes to wait to be majority comitted.
OpTimeWaitingMap _queuedOpTimes;
diff --git a/src/mongo/db/storage/kv/kv_prefix.cpp b/src/mongo/db/storage/kv/kv_prefix.cpp
index 1a54a82f6a1..c6cb732ad9f 100644
--- a/src/mongo/db/storage/kv/kv_prefix.cpp
+++ b/src/mongo/db/storage/kv/kv_prefix.cpp
@@ -31,7 +31,7 @@
namespace mongo {
int64_t KVPrefix::_nextValue = 0;
-Mutex KVPrefix::_nextValueMutex = MONGO_MAKE_LATCH();
+Mutex KVPrefix::_nextValueMutex = MONGO_MAKE_LATCH("KVPrefix::_nextValueMutex");
const KVPrefix KVPrefix::kNotPrefixed = KVPrefix(-1);
std::string KVPrefix::toString() const {
diff --git a/src/mongo/s/client/shard_registry.h b/src/mongo/s/client/shard_registry.h
index 2b9e839394f..a69785a19e3 100644
--- a/src/mongo/s/client/shard_registry.h
+++ b/src/mongo/s/client/shard_registry.h
@@ -114,7 +114,7 @@ private:
void _rebuildShard(WithLock, ConnectionString const& newConnString, ShardFactory* factory);
// Protects the lookup maps below.
- mutable Mutex _mutex = MONGO_MAKE_LATCH("::_mutex");
+ mutable Mutex _mutex = MONGO_MAKE_LATCH("ShardRegistryData::_mutex");
using ShardMap = stdx::unordered_map<ShardId, std::shared_ptr<Shard>, ShardId::Hasher>;