File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -125,6 +125,12 @@ The following code shows how to connect to a replica set deployment:
125
125
:start-after: start-replica-set-uri
126
126
:end-before: end-replica-set-uri
127
127
128
+ .. tip::
129
+
130
+ To maintain your connection to a replica set deployment when one
131
+ host is down, you can provide multiple replica set members in the
132
+ connection URI.
133
+
128
134
To learn more about connecting to a replica set, see :ref:`php-connection-replica-set`
129
135
in the Connection Targets guide.
130
136
@@ -290,8 +296,8 @@ client certificate:
290
296
291
297
.. important::
292
298
293
- When replacing the ``<password>`` placeholder, ensure that you :wikipedia:`percent-encode
294
- <Percent-encoding>` the value.
299
+ When replacing the ``<password>`` placeholder in the connection URI, ensure
300
+ that you :wikipedia:`percent-encode <Percent-encoding>` the value.
295
301
296
302
To learn more about providing a key file password, see :ref:`php-key-file-password` in
297
303
the TLS Configuration guide.
Original file line number Diff line number Diff line change 168
168
169
169
// Connects to a MongoDB deployment and enables the stable API
170
170
// start-stable-api
171
- $ driverOptions = ['serverApi ' => new MongoDB \Driver \ServerApi (ServerApi:: V1 )];
171
+ $ driverOptions = ['serverApi ' => new MongoDB \Driver \ServerApi (' 1 ' )];
172
172
$ client = new MongoDB \Client (
173
173
'mongodb://<hostname>:<port>/ ' ,
174
174
[],
You can’t perform that action at this time.
0 commit comments