summaryrefslogtreecommitdiff
path: root/src/mongo/s/query
diff options
context:
space:
mode:
authorMisha Tyulenev <misha@mongodb.com>2015-08-12 12:43:32 -0400
committerMisha Tyulenev <misha@mongodb.com>2015-08-12 13:14:40 -0400
commitd2fe88e34a93fb6d403307bd6b890d4f45d6935a (patch)
tree491a9a5da25e343d3764d604ef9037728c10bee1 /src/mongo/s/query
parentd7faf7b45890b1a995a7bf3c07c22ff41851dd53 (diff)
downloadmongo-d2fe88e34a93fb6d403307bd6b890d4f45d6935a.tar.gz
SERVER-18772 Add ntoreturn to LiteParsedQuery
Diffstat (limited to 'src/mongo/s/query')
-rw-r--r--src/mongo/s/query/cluster_find.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mongo/s/query/cluster_find.cpp b/src/mongo/s/query/cluster_find.cpp
index d3f03681a1a..5e0a9957323 100644
--- a/src/mongo/s/query/cluster_find.cpp
+++ b/src/mongo/s/query/cluster_find.cpp
@@ -74,6 +74,7 @@ std::unique_ptr<LiteParsedQuery> transformQueryForShards(const LiteParsedQuery&
boost::none, // Don't forward skip.
newLimit,
lpq.getBatchSize(),
+ lpq.getNToReturn(),
lpq.wantMore(),
lpq.isExplain(),
lpq.getComment(),
@@ -117,6 +118,7 @@ StatusWith<CursorId> runQueryWithoutRetrying(OperationContext* txn,
}
ClusterClientCursorParams params(query.nss());
+ params.limit = query.getParsed().getLimit();
params.batchSize = query.getParsed().getBatchSize();
params.limit = query.getParsed().getLimit();
params.sort = query.getParsed().getSort();