[CDRIVER-2122] Issues in documentation for read concern option "level" Created: 06/Apr/17  Updated: 06/May/17  Resolved: 06/May/17

Status: Closed
Project: C Driver
Component/s: docs
Affects Version/s: None
Fix Version/s: 1.7.0

Type: Bug Priority: Major - P3
Reporter: J Rassi Assignee: A. Jesse Jiryu Davis
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by CXX-1062 read_concern::acknowledge_string() cr... Closed
Related
related to CXX-1302 Documentation for read_concern::ackno... Closed

 Description   

There are several issues in the mongoc_read_concern_t documentation regarding the server default read concern:

  1. The documentation for mongoc_read_concern_get_level states that the empty string is returned when no read concern is set. However, 1.6.2, NULL is returned in this case, not the empty string.
  2. Similarly, the documentation for read_concern_t contains the same error regarding the empty string, in the "Synopsis" section.
  3. The documentation for mongoc_read_concern_set_level does not state how to set the server default read concern (the current wording implies that neither NULL nor the empty string are valid values to pass in for "level").

On a related note, the wording for the documentation of the parameter "level" in mongoc_read_concern_set_level() could be improved for the driver to be in better compliance with the Read and Write Concern spec. In particular, the spec states: "For forward compatibility, a driver MUST NOT raise an error when a user provides an unknown level...". In the hypothetical scenario where MongoDB 3.6 is released with a new read concern "foo", the C driver 1.6.2 documentation implies that "foo" is not a valid value to pass into the mongoc_read_concern_set_level() function when connected to this server.



 Comments   
Comment by Githook User [ 06/May/17 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: CDRIVER-2122 update readConcern docs
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/bd105b95489a1b2e34e114b4802f5c858af8da54

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