diff options
author | Andy Schwerin <schwerin@mongodb.com> | 2016-09-06 16:57:35 -0400 |
---|---|---|
committer | Andy Schwerin <schwerin@mongodb.com> | 2016-09-07 09:26:50 -0400 |
commit | 645a77b3fa5b28d29d245e30cc195fd5a8eda049 (patch) | |
tree | d91a9bc7ed7012e753ec8d92859f7f342a994f86 /src/mongo/client/remote_command_targeter_mock.h | |
parent | 1f389ce467330cda1171d2a04bd0e0b2890aaf8d (diff) | |
download | mongo-645a77b3fa5b28d29d245e30cc195fd5a8eda049.tar.gz |
SERVER-24600 Increase interruptibility of RemoteCommandTargeter::findHost.
By making more calls of RemoteCommandTargeter::findHost interruptible, this
change speeds up the shutdown of mongos when no config servers are discoverable.
Diffstat (limited to 'src/mongo/client/remote_command_targeter_mock.h')
-rw-r--r-- | src/mongo/client/remote_command_targeter_mock.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mongo/client/remote_command_targeter_mock.h b/src/mongo/client/remote_command_targeter_mock.h index d4c8835b619..6183a635f61 100644 --- a/src/mongo/client/remote_command_targeter_mock.h +++ b/src/mongo/client/remote_command_targeter_mock.h @@ -54,8 +54,11 @@ public: * Returns the return value last set by setFindHostReturnValue. * Returns ErrorCodes::InternalError if setFindHostReturnValue was never called. */ - StatusWith<HostAndPort> findHost(const ReadPreferenceSetting& readPref, - Milliseconds maxWait) override; + StatusWith<HostAndPort> findHostWithMaxWait(const ReadPreferenceSetting& readPref, + Milliseconds maxWait) override; + + StatusWith<HostAndPort> findHost(OperationContext* txn, + const ReadPreferenceSetting& readPref) override; /** * No-op for the mock. |