[GODRIVER-1773] Reduce batchSize for getMore commands to match number of required documents Created: 22/Oct/20  Updated: 14/Dec/20  Resolved: 14/Dec/20

Status: Closed
Project: Go Driver
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Divjot Arora (Inactive) Assignee: Unassigned
Resolution: Won't Fix Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to DRIVERS-956 Command monitoring find tests are out... Closed

 Description   

For 3.2+ servers, if we run a "find" with limit=4 and batchSize=3 and iterate the resulting cursor, we'll send both a "find" and a "getMore" with batchSize=3. For the getMore, we can technically reduce the batchSize to 1 because we only need 1 document to satisfy the limit.

This is not a correctness issue because 3.2+ servers maintain the limit server-side so they will close the cursor automatically once it has been exhausted. One of the command monitoring spec tests relies on this behavior, though, so we're currently skipping it because we don't do this.


Generated at Thu Feb 08 08:37:06 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.