Skip to content

Commit 08148a5

Browse files
authored
DOCSP-30768 Adds SRV connection option (#147)
* DOCSP-30768 Adds SRV connection option * Fixes build issue * Fixes build issue * Fixes per Ali * Refactors Atlas connection callout * Fixes build issue
1 parent b2fba47 commit 08148a5

File tree

4 files changed

+43
-7
lines changed

4 files changed

+43
-7
lines changed

source/connecting/atlas-to-atlas.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Atlas cluster, see :ref:`Connect to a Database Deployment
2222
Connection Strings
2323
------------------
2424

25-
.. include:: /includes/fact-connection-strings
25+
.. include:: /includes/fact-connection-strings-atlas
2626

2727
Authentication
2828
--------------

source/connecting/onprem-to-atlas.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ For additional details on connecting to an Atlas cluster, see
2424
Connection Strings
2525
------------------
2626

27-
.. include:: /includes/fact-connection-strings
27+
.. include:: /includes/fact-connection-strings-atlas
2828

2929
Authentication
3030
--------------
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
:ref:`mongosync <c2c-mongosync>` uses a :ref:`MongoDB URI
2+
connection string <mongodb-uri>` to connect clusters:
3+
4+
- The SRV connection scheme has the form:
5+
6+
.. code-block:: none
7+
8+
mongodb+srv://[username:password@][host.domain.TLD][:port][/defaultauthdb][?options]
9+
10+
For information on how to find your SRV connection
11+
string in Atlas, see :atlas:`Connect to Your Cluster
12+
</tutorial/connect-to-your-cluster>`.
13+
14+
- The standard URI connection scheme has the form:
15+
16+
.. code-block:: none
17+
18+
mongodb://[username:password@]host1[:port1][,...hostN[:portN]][/[defaultauthdb][?options]]
19+
20+
Specify the hostnames of the :binary:`mongod` instances the same way
21+
that they are listed in your replica set configuration.
22+
23+
For :ref:`sharded clusters <sharding-sharded-cluster>`, specify the
24+
hostnames of the :binary:`mongos` instances instead of the
25+
:binary:`mongod` instances.
26+
27+
.. note::
28+
29+
``mongosync`` does not require the :urioption:`replicaSet` option.
30+

source/includes/fact-connection-strings.rst

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,17 @@
1-
:ref:`mongosync <c2c-mongosync>` uses a standard :ref:`MongoDB URI
2-
connection string <mongodb-uri>` to connect clusters.
1+
:ref:`mongosync <c2c-mongosync>` uses a :ref:`MongoDB URI
2+
connection string <mongodb-uri>` to connect clusters:
33

4-
The standard URI connection scheme has the form:
4+
- The SRV connection scheme has the form:
55

6-
.. code-block:: none
6+
.. code-block:: none
77
8-
mongodb://[username:password@]host1[:port1][,...hostN[:portN]][/[defaultauthdb][?options]]
8+
mongodb+srv://[username:password@][host.domain.TLD][:port][/defaultauthdb][?options]
9+
10+
- The standard URI connection scheme has the form:
11+
12+
.. code-block:: none
13+
14+
mongodb://[username:password@]host1[:port1][,...hostN[:portN]][/[defaultauthdb][?options]]
915
1016
Specify the hostnames of the :binary:`mongod` instances the same way
1117
that they are listed in your replica set configuration.

0 commit comments

Comments
 (0)