Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions source/fundamentals/authentication/x509.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,12 @@ Code Placeholders

The code examples on this page use the following placeholders:

- ``+srv``: Include this option in your connection string prefix only if you are connecting
to a MongoDB Atlas cluster. To learn more about the ``+srv`` option, see
:manual:`Connection String Formats </reference/connection-string/#connection-string-formats>`
in the {+mdb-server+} manual.
- ``+srv``: Include this option in your connection string prefix only if you are
connecting to a MongoDB Atlas cluster. If you're using a
``MongoClientSettings`` object, you can specify the ``srv`` format by setting
the ``Scheme`` property to ``ConnectionStringScheme.MongoDBPlusSrv``. To learn
more about the ``+srv`` option, see :manual:`Connection String Formats </reference/connection-string/#connection-string-formats>` in the
{+mdb-server+} manual.
- ``<hostname>``: The network address of your MongoDB deployment.
- ``<port>``: The port number of the MongoDB deployment. If you omit this parameter,
the driver uses the default port number (``27017``). You don't need a port number
Expand Down Expand Up @@ -119,6 +121,7 @@ see the corresponding syntax:
},
UseTls = true,
Server = new MongoServerAddress("<hostname>"[, "<port>"]),
Scheme = ConnectionStringScheme.MongoDBPlusSrv, // Needed when connecting to MongoDB Atlas
};

Troubleshooting
Expand Down