summaryrefslogtreecommitdiff
path: root/src/mongo/util/net
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/util/net')
-rw-r--r--src/mongo/util/net/hostname_canonicalization.cpp2
-rw-r--r--src/mongo/util/net/http_client_curl.cpp2
-rw-r--r--src/mongo/util/net/http_client_winhttp.cpp2
-rw-r--r--src/mongo/util/net/openssl_init.cpp2
-rw-r--r--src/mongo/util/net/private/ssl_expiration.cpp2
-rw-r--r--src/mongo/util/net/sock.cpp14
-rw-r--r--src/mongo/util/net/sock.h10
-rw-r--r--src/mongo/util/net/socket_utils.cpp2
-rw-r--r--src/mongo/util/net/ssl/detail/impl/engine_apple.ipp2
-rw-r--r--src/mongo/util/net/ssl_manager.cpp2
-rw-r--r--src/mongo/util/net/ssl_manager_apple.cpp2
-rw-r--r--src/mongo/util/net/ssl_manager_openssl.cpp2
-rw-r--r--src/mongo/util/net/ssl_manager_windows.cpp2
-rw-r--r--src/mongo/util/net/ssl_options.cpp2
-rw-r--r--src/mongo/util/net/ssl_options_server.cpp2
-rw-r--r--src/mongo/util/net/ssl_parameters.cpp2
16 files changed, 26 insertions, 26 deletions
diff --git a/src/mongo/util/net/hostname_canonicalization.cpp b/src/mongo/util/net/hostname_canonicalization.cpp
index 2743cf20539..3f5b939cb18 100644
--- a/src/mongo/util/net/hostname_canonicalization.cpp
+++ b/src/mongo/util/net/hostname_canonicalization.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/http_client_curl.cpp b/src/mongo/util/net/http_client_curl.cpp
index f0b15bf5bc6..c3002d4f062 100644
--- a/src/mongo/util/net/http_client_curl.cpp
+++ b/src/mongo/util/net/http_client_curl.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/http_client_winhttp.cpp b/src/mongo/util/net/http_client_winhttp.cpp
index db80bcf2150..45e3bcbd205 100644
--- a/src/mongo/util/net/http_client_winhttp.cpp
+++ b/src/mongo/util/net/http_client_winhttp.cpp
@@ -34,7 +34,7 @@
#error This file assumes a UNICODE WIN32 build
#endif
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/openssl_init.cpp b/src/mongo/util/net/openssl_init.cpp
index 0e6b9e87014..c4980bb0042 100644
--- a/src/mongo/util/net/openssl_init.cpp
+++ b/src/mongo/util/net/openssl_init.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/private/ssl_expiration.cpp b/src/mongo/util/net/private/ssl_expiration.cpp
index 9bdcc797cec..59810487b11 100644
--- a/src/mongo/util/net/private/ssl_expiration.cpp
+++ b/src/mongo/util/net/private/ssl_expiration.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kControl
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kControl
#include "mongo/util/net/private/ssl_expiration.h"
diff --git a/src/mongo/util/net/sock.cpp b/src/mongo/util/net/sock.cpp
index 574c33e2b1a..206e0b65e22 100644
--- a/src/mongo/util/net/sock.cpp
+++ b/src/mongo/util/net/sock.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
@@ -225,14 +225,14 @@ Socket::Socket(int fd, const SockAddr& remote)
_remote(remote),
_timeout(0),
_lastValidityCheckAtSecs(time(nullptr)),
- _logLevel(logger::LogSeverity::Log()) {
+ _logLevel(logv2::LogSeverity::Log()) {
_init();
if (fd >= 0) {
_local = getLocalAddrForBoundSocketFd(_fd);
}
}
-Socket::Socket(double timeout, logger::LogSeverity ll) : _logLevel(ll) {
+Socket::Socket(double timeout, logv2::LogSeverity ll) : _logLevel(ll) {
_fd = INVALID_SOCKET;
_timeout = timeout;
_lastValidityCheckAtSecs = time(nullptr);
@@ -576,7 +576,7 @@ void Socket::handleSendError(int ret, const char* context) {
if ((mongo_errno == EAGAIN || mongo_errno == EWOULDBLOCK) && _timeout != 0) {
#endif
LOGV2_DEBUG(23181,
- logSeverityV1toV2(_logLevel).toInt(),
+ _logLevel.toInt(),
"Socket {context} send() timed out {remoteHost}",
"Socket send() to remote host timed out",
"context"_attr = context,
@@ -584,7 +584,7 @@ void Socket::handleSendError(int ret, const char* context) {
throwSocketError(SocketErrorKind::SEND_TIMEOUT, remoteString());
} else if (mongo_errno != EINTR) {
LOGV2_DEBUG(23182,
- logSeverityV1toV2(_logLevel).toInt(),
+ _logLevel.toInt(),
"Socket {context} send() {error} {remoteHost}",
"Socket send() to remote host failed",
"context"_attr = context,
@@ -624,7 +624,7 @@ void Socket::handleRecvError(int ret, int len) {
#endif
// this is a timeout
LOGV2_DEBUG(23184,
- logSeverityV1toV2(_logLevel).toInt(),
+ _logLevel.toInt(),
"Socket recv() timeout {remoteHost}",
"Socket recv() timeout",
"remoteHost"_attr = remoteString());
@@ -632,7 +632,7 @@ void Socket::handleRecvError(int ret, int len) {
}
LOGV2_DEBUG(23185,
- logSeverityV1toV2(_logLevel).toInt(),
+ _logLevel.toInt(),
"Socket recv() {error} {remoteHost}",
"Socket recv() error",
"error"_attr = errnoWithDescription(e),
diff --git a/src/mongo/util/net/sock.h b/src/mongo/util/net/sock.h
index dcaf44cd417..acb059bd5b3 100644
--- a/src/mongo/util/net/sock.h
+++ b/src/mongo/util/net/sock.h
@@ -51,7 +51,7 @@
#include <vector>
#include "mongo/config.h"
-#include "mongo/logger/log_severity.h"
+#include "mongo/logv2/log_severity.h"
#include "mongo/platform/compiler.h"
#include "mongo/util/assert_util.h"
#include "mongo/util/duration.h"
@@ -97,7 +97,7 @@ public:
Generally you don't want a timeout, you should be very prepared for errors if you set one.
*/
- Socket(double so_timeout = 0, logger::LogSeverity logLevel = logger::LogSeverity::Log());
+ Socket(double so_timeout = 0, logv2::LogSeverity logLevel = logv2::LogSeverity::Log());
~Socket();
@@ -124,10 +124,10 @@ public:
void recv(char* data, int len);
int unsafe_recv(char* buf, int max);
- logger::LogSeverity getLogLevel() const {
+ logv2::LogSeverity getLogLevel() const {
return _logLevel;
}
- void setLogLevel(logger::LogSeverity ll) {
+ void setLogLevel(logv2::LogSeverity ll) {
_logLevel = ll;
}
@@ -240,7 +240,7 @@ private:
std::unique_ptr<SSLConnectionInterface> _sslConnection;
SSLManagerInterface* _sslManager;
#endif
- logger::LogSeverity _logLevel; // passed to log() when logging errors
+ logv2::LogSeverity _logLevel; // passed to log() when logging errors
/** true until the first packet has been received or an outgoing connect has been made */
bool _awaitingHandshake;
diff --git a/src/mongo/util/net/socket_utils.cpp b/src/mongo/util/net/socket_utils.cpp
index 3d321bf3810..5e1909969a1 100644
--- a/src/mongo/util/net/socket_utils.cpp
+++ b/src/mongo/util/net/socket_utils.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/ssl/detail/impl/engine_apple.ipp b/src/mongo/util/net/ssl/detail/impl/engine_apple.ipp
index c88c0c756f3..015a44fcee8 100644
--- a/src/mongo/util/net/ssl/detail/impl/engine_apple.ipp
+++ b/src/mongo/util/net/ssl/detail/impl/engine_apple.ipp
@@ -30,7 +30,7 @@
#pragma once
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "asio/detail/config.hpp"
diff --git a/src/mongo/util/net/ssl_manager.cpp b/src/mongo/util/net/ssl_manager.cpp
index e162ac28c49..455a1662a57 100644
--- a/src/mongo/util/net/ssl_manager.cpp
+++ b/src/mongo/util/net/ssl_manager.cpp
@@ -28,7 +28,7 @@
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/ssl_manager_apple.cpp b/src/mongo/util/net/ssl_manager_apple.cpp
index 31740d4e4a4..10571b763ef 100644
--- a/src/mongo/util/net/ssl_manager_apple.cpp
+++ b/src/mongo/util/net/ssl_manager_apple.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/ssl_manager_openssl.cpp b/src/mongo/util/net/ssl_manager_openssl.cpp
index 91b5a7341f0..28a5adf1969 100644
--- a/src/mongo/util/net/ssl_manager_openssl.cpp
+++ b/src/mongo/util/net/ssl_manager_openssl.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/ssl_manager_windows.cpp b/src/mongo/util/net/ssl_manager_windows.cpp
index ec50095fa05..7dba187e380 100644
--- a/src/mongo/util/net/ssl_manager_windows.cpp
+++ b/src/mongo/util/net/ssl_manager_windows.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/ssl_options.cpp b/src/mongo/util/net/ssl_options.cpp
index 973f566c8ba..08e135b0cb6 100644
--- a/src/mongo/util/net/ssl_options.cpp
+++ b/src/mongo/util/net/ssl_options.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kControl
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kControl
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/ssl_options_server.cpp b/src/mongo/util/net/ssl_options_server.cpp
index b3f2e892a90..c8621383255 100644
--- a/src/mongo/util/net/ssl_options_server.cpp
+++ b/src/mongo/util/net/ssl_options_server.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kControl
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kControl
#include "mongo/platform/basic.h"
diff --git a/src/mongo/util/net/ssl_parameters.cpp b/src/mongo/util/net/ssl_parameters.cpp
index 1ebc409f0be..32de6a369f5 100644
--- a/src/mongo/util/net/ssl_parameters.cpp
+++ b/src/mongo/util/net/ssl_parameters.cpp
@@ -27,7 +27,7 @@
* it in the license file.
*/
-#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kNetwork
+#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kNetwork
#include "mongo/platform/basic.h"