diff options
author | Hugh Han <hughhan1@gmail.com> | 2017-08-10 15:14:49 -0400 |
---|---|---|
committer | Hugh Han <hughhan1@gmail.com> | 2017-08-10 15:14:49 -0400 |
commit | 6e4604101b8cca0dbab08ba386b56b6ad882292f (patch) | |
tree | 71fdf57038b1e782e0ede5d6c1cb3ab53f642d97 /src/mongo/s/client | |
parent | 53db8a7a0cde13aa0c54c6979843faac7fa8332e (diff) | |
download | mongo-6e4604101b8cca0dbab08ba386b56b6ad882292f.tar.gz |
Revert "SERVER-30546 Use Command::filterCommandReplyForPassthrough() for filtering response in ShardRemote::_runCommand"
This reverts commit 30688eaf7e47e5ed70dae50b73589f668d895722.
Diffstat (limited to 'src/mongo/s/client')
-rw-r--r-- | src/mongo/s/client/shard_remote.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/s/client/shard_remote.cpp b/src/mongo/s/client/shard_remote.cpp index b00ed3f5913..e75af4c8554 100644 --- a/src/mongo/s/client/shard_remote.cpp +++ b/src/mongo/s/client/shard_remote.cpp @@ -40,7 +40,6 @@ #include "mongo/client/remote_command_retry_scheduler.h" #include "mongo/client/remote_command_targeter.h" #include "mongo/client/replica_set_monitor.h" -#include "mongo/db/commands.h" #include "mongo/db/jsobj.h" #include "mongo/db/operation_context.h" #include "mongo/db/query/query_request.h" @@ -215,14 +214,15 @@ StatusWith<Shard::CommandResponse> ShardRemote::_runCommand(OperationContext* op return response.status; } - auto commandStatus = getStatusFromCommandResult(response.data); - auto writeConcernStatus = getWriteConcernStatusFromCommandResult(response.data); + auto result = response.data.getOwned(); + auto commandStatus = getStatusFromCommandResult(result); + auto writeConcernStatus = getWriteConcernStatusFromCommandResult(result); updateReplSetMonitor(host, commandStatus); updateReplSetMonitor(host, writeConcernStatus); return Shard::CommandResponse(std::move(host), - Command::filterCommandReplyForPassthrough(response.data), + std::move(result), response.metadata.getOwned(), std::move(commandStatus), std::move(writeConcernStatus)); |