[CDRIVER-4115] Support batchSize on listCollections helper Created: 04/Aug/21  Updated: 18/Sep/23

Status: Backlog
Project: C Driver
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Unknown
Reporter: Kevin Albertson Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: bg-rf
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: File example-batchsize-collections.c    
Issue Links:
Related
related to CDRIVER-4116 Support batchSize on listIndexes helper Backlog
Epic Link: Improve Developer Experience

 Description   

Motivation
The C driver does not support the batchSize option on the listCollections helper: mongoc_database_find_collections_with_opts.

The attachment includes a reproduction script. It is possible to pass a batch size to the initial listCollections command by passing option as the document: {cursor:{batchSize: 1}}.

However, any getMore command sent by the cursor when fetching more results does not use the same batchSize.

The Enumerate Collections specification does note this behavior is optional:

MAY allow the cursor.batchSize option to be passed.

Scope

Accept a batchSize as a top-level option, which applies to both the initial listCollections command and all getMore operations.


Generated at Wed Feb 07 21:19:58 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.