Skip to content

Commit f21bd59

Browse files
committed
trivial: add headings to setReadPref
1 parent 8705e2b commit f21bd59

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

source/reference/method/Mongo.setReadPref.txt

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,20 @@ Definition
5151
Examples
5252
--------
5353

54-
To set a read preference mode in the :binary:`~bin.mongo` shell, use the
55-
following operation:
54+
55+
Specify Read Preference Mode
56+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
57+
58+
The following operation in the :binary:`~bin.mongo` shell sets the read
59+
preference :ref:`mode <mongo-setReadPref-mode>` to allow reads from
60+
secondary members and target the read to a secondary member.
5661

5762
.. code-block:: javascript
5863

59-
db.getMongo().setReadPref('primaryPreferred')
64+
db.getMongo().setReadPref('secondary')
65+
66+
Specify Read Preference Tag Set
67+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
6068

6169
To set a read preference that uses a tag set, specify an array of tag
6270
sets as the second argument to :method:`Mongo.setReadPref()`, as in the

0 commit comments

Comments
 (0)