DOCSP-59346 Connection Option Template#158
Conversation
stephmarie17
left a comment
There was a problem hiding this comment.
Awesome work, Lindsey! This will make the connection options revamp so much easier. Left some comments and a few questions, mostly around whether all the :manual: links should be updated to use :ref:, and some usage suggestions.
| If you specify this option, the driver doesn't accept the | ||
| SRV connection format. You must use the standard connection URI format | ||
| instead. To learn more about the SRV connection | ||
| and the standard connection formats, see the :manual:`Connection Strings </reference/connection-string/>` |
There was a problem hiding this comment.
[q] Are we still planning to move :manual: links to :ref:?
| and the standard connection formats, see the :manual:`Connection Strings </reference/connection-string/>` | |
| and the standard connection formats, see the :ref:`Connection Strings <mongodb-uri>` |
There was a problem hiding this comment.
If so, applies to all.
There was a problem hiding this comment.
Thanks, replaced all :manuals: links!
| @@ -0,0 +1,1305 @@ | |||
| .. _c-connection-options: | |||
There was a problem hiding this comment.
[s] Maybe rename this so it's clearer it's meant to be changed and doesn't accidentally get carried over to another driver:
| .. _c-connection-options: | |
| .. _template-connection-options: |
There was a problem hiding this comment.
Good idea! Replaced all instances of 'c' in refs to 'template'
| How to Specify Connection Options | ||
| --------------------------------- | ||
|
|
||
| .. TODO: Replace these sections with whatever methods for specify the connection option. |
There was a problem hiding this comment.
| .. TODO: Replace these sections with whatever methods for specify the connection option. | |
| .. TODO: Replace these sections with whatever methods the driver you are documenting supports for specifying the connection option. |
| *Data Type* : | ||
|
|
||
| *Default Value* : |
There was a problem hiding this comment.
[q] Are these required? Just wondering as the existing C driver page doesn't have this part so curious how it looks when rendered and if they are required to have a value specific to each driver?
There was a problem hiding this comment.
I started on C; here's what it will look like rendered: https://deploy-preview-19608--mongodb-c-driver.netlify.app/docs/languages/c/c-driver/upcoming/connect/connection-options/#replica-set-options
Please let me know what you think of how it looks!
We will have to hunt down the data type and defaults values for each of these options. Some drivers already have this info, some don't.
There was a problem hiding this comment.
Gotcha that makes sense! I think that preview looks good maybe use bold instead of italics, similar to how we format the text in the tables? What do you think?
| You can set the read concern level by using the ``MONGOC_URI_READCONCERNLEVEL`` option: | ||
|
|
||
| .. literalinclude:: | ||
| :language: | ||
| :copyable: true | ||
| :dedent: | ||
| :start-after: | ||
| :end-before: | ||
|
|
||
| You can also set the read concern level by using a ``mongoc_read_concern_t`` structure: |
There was a problem hiding this comment.
[q] Is this also driver-specific and should it include a TODO to call it out?
| You can set the read preference by using a ``mongoc_read_prefs_t`` structure: | ||
|
|
||
| .. literalinclude:: | ||
| :language: | ||
| :copyable: true | ||
| :dedent: | ||
| :start-after: | ||
| :end-before: | ||
|
|
||
| You can also set the read preference by using the ``MONGOC_URI_READPREFERENCE`` option: |
| :start-after: | ||
| :end-before: | ||
|
|
||
| You can also set the max staleness by using a ``mongoc_read_prefs_t`` structure: |
| @@ -0,0 +1,1305 @@ | |||
| .. _c-connection-options: | |||
|
|
|||
| .. NOTE: Meant to be copied and used as a template for the connection options page. | |||
There was a problem hiding this comment.
[s] Suggestion to explain the usage of this doc more:
| .. NOTE: Meant to be copied and used as a template for the connection options page. | |
| .. NOTE: You can use this template for the connection options page in a drivers documentation set. Copy this content into the corresponding page for the driver you are documenting, and replace and edit content as needed. This is not meant to be used as a shared include. |
There was a problem hiding this comment.
In case writers think they can include this and then use replace or something for whatever their specific content is.
There was a problem hiding this comment.
Perfect, thanks!
stephmarie17
left a comment
There was a problem hiding this comment.
LGTM! Left a suggestion in one comment.
| *Data Type* : | ||
|
|
||
| *Default Value* : |
There was a problem hiding this comment.
Gotcha that makes sense! I think that preview looks good maybe use bold instead of italics, similar to how we format the text in the tables? What do you think?
Jira: https://jira.mongodb.org/browse/DOCSP-59346
Creates a template for new Connection Options page format and option descriptions for page.
Option descriptions and template are adapted from the current C Driver Connection Options page.