diff options
author | Amirsaman Memaripour <amirsaman.memaripour@mongodb.com> | 2020-11-02 17:38:29 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-11-24 18:37:06 +0000 |
commit | 40c3bac93c2091cea665de686cae93ef90429775 (patch) | |
tree | ce51224ab1bce9a17d9b62d095d03c0bb16de9fa /src/mongo/s/commands/cluster_command_test_fixture.cpp | |
parent | 5e82f974f44a822753ad0656692a1011a6611b3c (diff) | |
download | mongo-40c3bac93c2091cea665de686cae93ef90429775.tar.gz |
SERVER-51690 Add support for async command execution to Mongos
Diffstat (limited to 'src/mongo/s/commands/cluster_command_test_fixture.cpp')
-rw-r--r-- | src/mongo/s/commands/cluster_command_test_fixture.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mongo/s/commands/cluster_command_test_fixture.cpp b/src/mongo/s/commands/cluster_command_test_fixture.cpp index 316fc78782f..8c8813a3b11 100644 --- a/src/mongo/s/commands/cluster_command_test_fixture.cpp +++ b/src/mongo/s/commands/cluster_command_test_fixture.cpp @@ -122,7 +122,9 @@ DbResponse ClusterCommandTestFixture::runCommand(BSONObj cmd) { auto clusterGLE = ClusterLastErrorInfo::get(client.get()); clusterGLE->newRequest(); - return Strategy::clientCommand(opCtx.get(), opMsgRequest.serialize()); + AlternativeClientRegion acr(client); + auto rec = std::make_shared<RequestExecutionContext>(opCtx.get(), opMsgRequest.serialize()); + return Strategy::clientCommand(std::move(rec)).get(); } void ClusterCommandTestFixture::runCommandSuccessful(BSONObj cmd, bool isTargeted) { |