[CXX-441] Support cursor in listCollections command Created: 08/Dec/14  Updated: 19/Dec/14  Resolved: 19/Dec/14

Status: Closed
Project: C++ Driver
Component/s: None
Affects Version/s: None
Fix Version/s: legacy-1.0.0-rc3

Type: Improvement Priority: Blocker - P1
Reporter: Barrie Segal Assignee: Tyler Brock
Resolution: Done Votes: 0
Labels: legacy-cxx
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by DRIVERS-197 Support cursor in listCollections and... Closed
Duplicate
is duplicated by CXX-447 listCollections and listIndexes helpe... Closed
Related
is related to CXX-449 Aggregate cursor with no results agai... Closed
is related to SERVER-16541 listCollections command result includ... Closed

 Comments   
Comment by Githook User [ 19/Dec/14 ]

Author:

{u'username': u'TylerBrock', u'name': u'Tyler Brock', u'email': u'tyler.brock@gmail.com'}

Message: CXX-441 support the new listCollections command format
Branch: legacy
https://github.com/mongodb/mongo-cxx-driver/commit/d812641f78a71d775ac5dd15d1f17f0a504edcdc

Comment by Tyler Brock [ 12/Dec/14 ]

Given that we have the shim infrastructure already this is what I came up with. I tested it against MongoDB 2.0.9 and master and it seems to work + pass all tests.

Ideally I'd have preferred if we had used the DBClientCursor constructor that takes the returned cursor id and used put_back to load up a stack of documents from the first batch as it would make the code a lot cleaner, shorter, and easier to understand, etc. The problem with that approach is that it's kind of a crazy hack (even more so than being able to put back results in to a cursor itself!)

https://github.com/mongodb/mongo-cxx-driver/pull/217

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