[CDRIVER-201] ReadPreference Created: 11/Mar/13  Updated: 16/Jul/15  Resolved: 11/Nov/13

Status: Closed
Project: C Driver
Component/s: None
Affects Version/s: 0.6, 0.7, 0.7.1
Fix Version/s: 0.90.0

Type: Bug Priority: Major - P3
Reporter: Andrea Fontana Assignee: Gary Murakami
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to CDRIVER-750 Queries sent to recovering members Closed

 Description   

From doc:
"MongoDB drivers support five read preference modes:"

C driver still doesn't support it.



 Comments   
Comment by Christian Hergert [ 11/Nov/13 ]

Hi Andrea,

The new C driver in development has this feature. The initial release is coming shortly, and I invite you to try it out and see how things work for you. Currently, the code can be found at https://github.com/chergert/libmongoc/

Using the new driver, you can create a read preference and use it in individual queries, or specify defaults on the client, database, or collection levels.

See https://github.com/chergert/libmongoc/blob/master/mongoc/mongoc-read-prefs.h#L32 for more information on the API.

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