summaryrefslogtreecommitdiff
path: root/src/mongo/client
diff options
context:
space:
mode:
authorBilly Donahue <billy.donahue@mongodb.com>2019-01-04 12:19:37 -0500
committerBilly Donahue <billy.donahue@mongodb.com>2019-01-07 12:08:23 -0500
commit11bb071e91461b1f8e40b9b15ddf3b9e1a2d23d1 (patch)
tree7037865f9bf4445fb3295ca7ce72f4182f012554 /src/mongo/client
parent6a0a21214dd96663c899cb8f2562d6121351ed3c (diff)
downloadmongo-11bb071e91461b1f8e40b9b15ddf3b9e1a2d23d1.tar.gz
SERVER-36644 remove AtomicWord typedefs
Diffstat (limited to 'src/mongo/client')
-rw-r--r--src/mongo/client/connpool.cpp2
-rw-r--r--src/mongo/client/connpool.h2
-rw-r--r--src/mongo/client/dbclient_base.cpp2
-rw-r--r--src/mongo/client/dbclient_base.h2
-rw-r--r--src/mongo/client/dbclient_connection.cpp2
-rw-r--r--src/mongo/client/dbclient_connection.h6
-rw-r--r--src/mongo/client/replica_set_monitor.cpp2
-rw-r--r--src/mongo/client/replica_set_monitor.h2
8 files changed, 10 insertions, 10 deletions
diff --git a/src/mongo/client/connpool.cpp b/src/mongo/client/connpool.cpp
index 56b6a85edfc..230ea33e049 100644
--- a/src/mongo/client/connpool.cpp
+++ b/src/mongo/client/connpool.cpp
@@ -674,7 +674,7 @@ void ScopedDbConnection::clearPool() {
globalConnPool.clear();
}
-AtomicInt32 AScopedConnection::_numConnections;
+AtomicWord<int> AScopedConnection::_numConnections;
MONGO_INITIALIZER(SetupDBClientBaseWithConnection)(InitializerContext*) {
DBClientBase::withConnection_do_not_use = [](std::string host,
diff --git a/src/mongo/client/connpool.h b/src/mongo/client/connpool.h
index c10cf59c9b8..bea0d840029 100644
--- a/src/mongo/client/connpool.h
+++ b/src/mongo/client/connpool.h
@@ -441,7 +441,7 @@ public:
}
private:
- static AtomicInt32 _numConnections;
+ static AtomicWord<int> _numConnections;
};
/** Use to get a connection from the pool. On exceptions things
diff --git a/src/mongo/client/dbclient_base.cpp b/src/mongo/client/dbclient_base.cpp
index b74f1fe9ec1..bd94e397811 100644
--- a/src/mongo/client/dbclient_base.cpp
+++ b/src/mongo/client/dbclient_base.cpp
@@ -101,7 +101,7 @@ SSLManagerInterface* sslManager() {
} // namespace
-AtomicInt64 DBClientBase::ConnectionIdSequence;
+AtomicWord<long long> DBClientBase::ConnectionIdSequence;
void (*DBClientBase::withConnection_do_not_use)(std::string host,
std::function<void(DBClientBase*)>) = nullptr;
diff --git a/src/mongo/client/dbclient_base.h b/src/mongo/client/dbclient_base.h
index 6f0458e95ee..f8aa0a41ff6 100644
--- a/src/mongo/client/dbclient_base.h
+++ b/src/mongo/client/dbclient_base.h
@@ -710,7 +710,7 @@ protected:
/** controls how chatty the client is about network errors & such. See log.h */
const logger::LogSeverity _logLevel;
- static AtomicInt64 ConnectionIdSequence;
+ static AtomicWord<long long> ConnectionIdSequence;
long long _connectionId; // unique connection id for this connection
private:
diff --git a/src/mongo/client/dbclient_connection.cpp b/src/mongo/client/dbclient_connection.cpp
index c494e7b6d51..51940bd819a 100644
--- a/src/mongo/client/dbclient_connection.cpp
+++ b/src/mongo/client/dbclient_connection.cpp
@@ -666,6 +666,6 @@ void DBClientConnection::handleNotMasterResponse(const BSONObj& replyBody,
_markFailed(kSetFlag);
}
-AtomicInt32 DBClientConnection::_numConnections;
+AtomicWord<int> DBClientConnection::_numConnections;
} // namespace mongo
diff --git a/src/mongo/client/dbclient_connection.h b/src/mongo/client/dbclient_connection.h
index ddadf5c0230..d7d58150257 100644
--- a/src/mongo/client/dbclient_connection.h
+++ b/src/mongo/client/dbclient_connection.h
@@ -301,8 +301,8 @@ protected:
uint64_t _sessionCreationMicros = INVALID_SOCK_CREATION_TIME;
Date_t _lastConnectivityCheck;
- AtomicBool _stayFailed{false};
- AtomicBool _failed{false};
+ AtomicWord<bool> _stayFailed{false};
+ AtomicWord<bool> _failed{false};
const bool autoReconnect;
Backoff autoReconnectBackoff;
@@ -315,7 +315,7 @@ protected:
bool _internalAuthOnReconnect = false;
std::map<std::string, BSONObj> authCache;
- static AtomicInt32 _numConnections;
+ static AtomicWord<int> _numConnections;
private:
/**
diff --git a/src/mongo/client/replica_set_monitor.cpp b/src/mongo/client/replica_set_monitor.cpp
index d78adff5a50..41c59fa9800 100644
--- a/src/mongo/client/replica_set_monitor.cpp
+++ b/src/mongo/client/replica_set_monitor.cpp
@@ -94,7 +94,7 @@ const int64_t unknownLatency = numeric_limits<int64_t>::max();
const ReadPreferenceSetting kPrimaryOnlyReadPreference(ReadPreference::PrimaryOnly, TagSet());
const Milliseconds kExpeditedRefreshPeriod(500);
-AtomicBool areRefreshRetriesDisabledForTest{false}; // Only true in tests.
+AtomicWord<bool> areRefreshRetriesDisabledForTest{false}; // Only true in tests.
// TODO: Move to ReplicaSetMonitorManager
ReplicaSetMonitor::ConfigChangeHook asyncConfigChangeHook;
diff --git a/src/mongo/client/replica_set_monitor.h b/src/mongo/client/replica_set_monitor.h
index 669e3de777e..ecfe03388a5 100644
--- a/src/mongo/client/replica_set_monitor.h
+++ b/src/mongo/client/replica_set_monitor.h
@@ -295,7 +295,7 @@ private:
executor::TaskExecutor::CallbackHandle _refresherHandle;
const SetStatePtr _state;
- AtomicBool _isRemovedFromManager{false};
+ AtomicWord<bool> _isRemovedFromManager{false};
};