[SERVER-20335] Mongos should not forward a getMore command to the shards with a batchSize of 0 Created: 09/Sep/15 Updated: 05/Oct/16 Resolved: 10/Sep/15 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Querying, Sharding |
| Affects Version/s: | None |
| Fix Version/s: | 3.1.8 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | David Storch | Assignee: | YunHe Wang |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||
| Operating System: | ALL | ||||||||
| Steps To Reproduce: | python buildscripts/resmoke.py --executor=sharding_jscore_passthrough jstests/core/find_getmore_bsonsize.js |
||||||||
| Sprint: | Quint 9 09/18/15 | ||||||||
| Participants: | |||||||||
| Description |
|
If the batchSize associated with the initial find command is zero, then the AsyncResultsMerger will send a batchSize of zero to the shards for subsequent getMore commands. Setting a batchSize of zero is illegal for the getMore command and the mongod will return a BadValue error: "Batch size for getMore must be positive, but received: 0". Instead, the getMore commands forwarded to the shards should not have a batchSize. In order to fix, we should not set the value of ClusterClientCursorParams::batchSize to boost::none rather than zero here: |
| Comments |
| Comment by Githook User [ 10/Sep/15 ] |
|
Author: {u'name': u'Yunhe (John) Wang', u'email': u'yunhe.wang@mongodb.com'}Message: Closes #1018 Signed-off-by: David Storch <david.storch@10gen.com> |