@@ -6,6 +6,10 @@ Connection Guide
6
6
7
7
.. default-domain:: mongodb
8
8
9
+ .. facet::
10
+ :name: genre
11
+ :values: tutorial
12
+
9
13
.. contents:: On this page
10
14
:local:
11
15
:backlinks: none
@@ -63,7 +67,7 @@ To connect to MongoDB, you need to create a client. A client manages
63
67
your connections and runs database commands.
64
68
65
69
.. tip:: Reuse Your Client
66
-
70
+
67
71
We recommend that you reuse your client across sessions and operations.
68
72
You can use the same ``Client`` instance to perform multiple tasks, instead of
69
73
creating a new one each time. The ``Client`` type is safe for
@@ -85,7 +89,7 @@ more about creating a client, see the API documentation for `Client
85
89
<{+api+}/mongo#Client>`__ and `Connect() <{+api+}/mongo#Connect>`__.
86
90
87
91
You can set the {+stable-api+} version as an option to avoid
88
- breaking changes when you upgrade to a new server version. To
92
+ breaking changes when you upgrade to a new server version. To
89
93
learn more about the {+stable-api+} feature, see the :ref:`{+stable-api+} page
90
94
<golang-stable-api>`.
91
95
@@ -278,7 +282,7 @@ amount of time that a single operation can take to execute using the
278
282
connection URI string. ``Database``, ``Collection``,
279
283
``Session``, ``ChangeStream``, and ``Bucket`` instances elsewhere in
280
284
your code inherit the ``Timeout`` option from ``Client`` if you do not set a
281
- Context for operations against the same entity.
285
+ Context for operations against the same entity.
282
286
283
287
If you pass a Context into an operation with a deadline, the driver uses
284
288
that Context deadline for the operation. If the context does not have a
@@ -319,4 +323,4 @@ URI option and execute an operation that inherits this setting:
319
323
will be deprecated in an upcoming release. The driver ignores ``MaxTime`` and
320
324
``MaxCommitTime`` if you set ``Timeout``. The driver still honors
321
325
``SocketTimeout`` and ``wTimeout``, but these settings may result in
322
- undefined behavior. Consider using only the single timeout option instead.
326
+ undefined behavior. Consider using only the single timeout option instead.
0 commit comments