diff options
| author | Lucas de Castro Borges <lucas@gnuabordo.com.br> | 2025-02-11 15:07:35 -0300 |
|---|---|---|
| committer | Lucas de Castro Borges <lucas@gnuabordo.com.br> | 2025-02-11 15:07:35 -0300 |
| commit | 4cb8841196d0625dfa3825aa326f071cd27c7b8b (patch) | |
| tree | 1682a647d4463397c119183369ae6f750d5fdcff /src/mongo/executor/network_interface_mock.h | |
| parent | aa03c6362cbaa767638e6eed9b031d86dd2643d1 (diff) | |
| parent | 8f0827553e09872941945a093b647a4211a9db7f (diff) | |
Update upstream source from tag 'upstream/6.0.0'master
Update to upstream version '6.0.0'
with Debian dir 5604a80ec1c96ca76f25f40d78e6ef855abec322
Diffstat (limited to 'src/mongo/executor/network_interface_mock.h')
| -rw-r--r-- | src/mongo/executor/network_interface_mock.h | 21 |
1 files changed, 2 insertions, 19 deletions
diff --git a/src/mongo/executor/network_interface_mock.h b/src/mongo/executor/network_interface_mock.h index b8610d58d9d..e096589d640 100644 --- a/src/mongo/executor/network_interface_mock.h +++ b/src/mongo/executor/network_interface_mock.h @@ -41,7 +41,6 @@ #include "mongo/stdx/condition_variable.h" #include "mongo/stdx/unordered_map.h" #include "mongo/stdx/unordered_set.h" -#include "mongo/transport/mock_session.h" #include "mongo/util/clock_source.h" #include "mongo/util/clock_source_mock.h" #include "mongo/util/time_support.h" @@ -149,20 +148,6 @@ public: void testEgress(const HostAndPort&, transport::ConnectSSLMode, Milliseconds, Status) override {} - using LeasedStreamMaker = - std::function<std::unique_ptr<NetworkInterface::LeasedStream>(HostAndPort)>; - - void setLeasedStreamMaker(LeasedStreamMaker lsm) { - _leasedStreamMaker = std::move(lsm); - } - - SemiFuture<std::unique_ptr<NetworkInterface::LeasedStream>> leaseStream( - const HostAndPort& hp, transport::ConnectSSLMode, Milliseconds) override { - invariant(_leasedStreamMaker, - "Tried to lease a stream from NetworkInterfaceMock without providing one"); - return (*_leasedStreamMaker)(hp); - } - //////////////////////////////////////////////////////////////////////////////// // // Methods for simulating network operations and the passage of time. @@ -288,9 +273,9 @@ public: void runReadyNetworkOperations(); /** - * Sets the reply of the 'hello' handshake for a specific host. This reply will only + * Sets the reply of the 'isMaster' handshake for a specific host. This reply will only * be given to the 'validateHost' method of the ConnectionHook set on this object - NOT - * to the completion handlers of any 'hello' commands scheduled with 'startCommand'. + * to the completion handlers of any 'isMaster' commands scheduled with 'startCommand'. * * This reply will persist until it is changed again using this method. * @@ -461,8 +446,6 @@ private: // The handshake replies set for each host. stdx::unordered_map<HostAndPort, RemoteCommandResponse> _handshakeReplies; // (M) - - boost::optional<LeasedStreamMaker> _leasedStreamMaker; }; /** |
