Skip to content

Commit 4af8e7d

Browse files
authored
DOCSP-24514 Adds interlinks for replication methods (#2525) (#2550)
* DOCSP-24514 Adds interlinks for replication methods * Fixes per Sarah Olson * Fixes per Sarah Olson
1 parent aa47923 commit 4af8e7d

14 files changed

+57
-27
lines changed

source/reference/command/replSetFreeze.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ replSetFreeze
1818
:dbcommand:`replSetStepDown` command to make a different node in
1919
the replica set a primary.
2020

21+
.. |method| replace:: :method:`rs.freeze` helper method
22+
.. include:: /includes/fact-dbcommand-tip.rst
23+
2124
The :dbcommand:`replSetFreeze` command uses the following syntax:
2225

2326
.. code-block:: javascript

source/reference/command/replSetGetConfig.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ Definition
1919
:term:`replica set`. To invoke the command directly, use the
2020
following operation:
2121

22+
.. |method| replace:: :method:`rs.conf` helper method
23+
.. include:: /includes/fact-dbcommand-tip.rst
24+
2225
.. code-block:: javascript
2326

2427
db.runCommand( { replSetGetConfig: 1 } );

source/reference/command/replSetGetStatus.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ Definition
2727
Because of the frequency of heartbeats, these data can be several
2828
seconds out of date.
2929

30+
.. |method| replace:: :method:`rs.status` helper method
31+
.. include:: /includes/fact-dbcommand-tip.rst
32+
33+
3034
Syntax
3135
------
3236

source/reference/command/replSetInitiate.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ replSetInitiate
1616

1717
.. |command| replace:: ``replSetInitiate``
1818

19+
.. |method| replace:: :method:`rs.initiate` helper method
20+
.. include:: /includes/fact-dbcommand-tip.rst
21+
1922
.. include:: /includes/fact-dbcommand.rst
2023

2124
.. note::

source/reference/command/replSetReconfig.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ replSetReconfig
1818
members. You must run this command on the ``admin``
1919
database of the :term:`primary` replica set member.
2020

21+
22+
.. |method| replace:: :method:`rs.reconfig` helper method
23+
.. include:: /includes/fact-dbcommand-tip.rst
24+
2125
The command has the following syntax:
2226

2327
.. code-block:: javascript

source/reference/command/replSetStepDown.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ Description
2121

2222
.. include:: /includes/stepdown-intro.rst
2323

24+
.. |method| replace:: :method:`rs.stepDown` helper method
25+
.. include:: /includes/fact-dbcommand-tip.rst
26+
2427
The :dbcommand:`replSetStepDown` can only run on the ``admin`` database
2528
and has the following prototype form:
2629

source/reference/command/replSetSyncFrom.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@ Description
2020
patterns and in situations where a set member is not replicating
2121
from the desired host.
2222

23-
.. include:: /includes/fact-voting-node-sync-incompatibility.rst
23+
.. |method| replace:: :method:`rs.syncFrom` helper method
24+
.. include:: /includes/fact-dbcommand-tip.rst
2425

2526
Run :dbcommand:`replSetSyncFrom` in the ``admin`` database.
2627

source/reference/method/rs.conf.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ Definition
1818
Returns a document that contains the current :term:`replica set`
1919
configuration.
2020

21-
The method wraps the :dbcommand:`replSetGetConfig` command.
21+
.. |dbcommand| replace:: :dbcommand:`replSetGetConfig` command
22+
.. include:: /includes/fact-mongo-shell-method-alt.rst
2223

2324
Output Example
2425
--------------

source/reference/method/rs.freeze.txt

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ Description
1818
Makes the current :term:`replica set` member ineligible to become
1919
:term:`primary` for the period specified.
2020

21+
.. |dbcommand| replace:: :dbcommand:`replSetFreeze` command
22+
.. include:: /includes/fact-mongo-shell-method-alt.rst
23+
2124
The :method:`rs.freeze()` method has the following parameter:
2225

2326

@@ -37,9 +40,3 @@ Description
3740

3841
- The duration the member is ineligible to become primary.
3942

40-
41-
42-
43-
44-
:method:`rs.freeze()` provides a wrapper around the :term:`database
45-
command` :dbcommand:`replSetFreeze`.

source/reference/method/rs.initiate.txt

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ Description
2020
:ref:`configuration of a replica set
2121
<replica-set-configuration-document>`.
2222

23+
.. |dbcommand| replace:: :dbcommand:`replSetInitiate` command
24+
.. include:: /includes/fact-mongo-shell-method-alt.rst
25+
2326
The :method:`rs.initiate()` method has the following parameter:
2427

2528

@@ -42,14 +45,6 @@ Description
4245
configuration is not specified, MongoDB uses a default
4346
replica set configuration.
4447

45-
46-
47-
48-
49-
The :method:`rs.initiate()` method provides a wrapper around the
50-
:dbcommand:`replSetInitiate` command.
51-
52-
5348
IP Binding
5449
----------
5550

source/reference/method/rs.reconfig.txt

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,20 @@ Definition
1919
replica set configuration. To run the method, you must connect to
2020
the :term:`primary` of the replica set.
2121

22+
.. |dbcommand| replace:: :dbcommand:`replSetReconfig` command
23+
.. include:: /includes/fact-mongo-shell-method-alt.rst
24+
25+
The :method:`rs.reconfig()` method has the following syntax:
26+
27+
.. code-block:: bash
28+
29+
rs.reconfig(
30+
<configuration>,
31+
{
32+
"force" : <boolean>,
33+
"maxTimeMS" : <int>
34+
}
35+
)
2236

2337
.. list-table::
2438
:header-rows: 1
@@ -56,9 +70,6 @@ Definition
5670
current configuration with :method:`rs.conf()`, modify the
5771
configuration document as needed, and then pass the modified
5872
document to :method:`rs.reconfig()`.
59-
60-
:method:`rs.reconfig()` provides a wrapper around the
61-
:dbcommand:`replSetReconfig` command.
6273

6374
The ``force`` parameter allows a reconfiguration command to be issued
6475
to a non-primary node.

source/reference/method/rs.status.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,10 @@ Definition
1616
.. method:: rs.status()
1717

1818
Returns the replica set status from the point of view of the member
19-
where the method is run. This method provides a wrapper around the
20-
:dbcommand:`replSetGetStatus` command.
19+
where the method is run.
20+
21+
.. |dbcommand| replace:: :dbcommand:`replSetGetStatus` command
22+
.. include:: /includes/fact-mongo-shell-method-alt.rst
2123

2224
This output reflects the current status of the replica set, using
2325
data derived from the heartbeat packets sent by the other members

source/reference/method/rs.stepDown.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ Description
2020
.. |behavior-ref| replace:: :ref:`rs.stepDown-behavior`
2121

2222
.. include:: /includes/stepdown-intro.rst
23+
24+
.. |dbcommand| replace:: :dbcommand:`replSetStepDown` command
25+
.. include:: /includes/fact-mongo-shell-method-alt.rst
2326

2427
The :method:`rs.stepDown()` method has the following parameters:
2528

@@ -62,8 +65,6 @@ Description
6265

6366

6467

65-
:method:`rs.stepDown()` provides a wrapper around the
66-
command :dbcommand:`replSetStepDown`.
6768

6869
.. _rs.stepDown-behavior:
6970

source/reference/method/rs.syncFrom.txt

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,14 @@ rs.syncFrom()
1212

1313
.. method:: rs.syncFrom()
1414

15-
Provides a wrapper around the :dbcommand:`replSetSyncFrom`, which
16-
allows administrators to temporarily override the default sync
17-
target for the current member. Specify the name of the member you
15+
Temporarily overrides the default sync target for the current member.
16+
17+
.. |dbcommand| replace:: :dbcommand:`replSetFreeze` command
18+
.. include:: /includes/fact-mongo-shell-method-alt.rst
19+
20+
Specify the name of the member you
1821
want to replicate from in the form of ``[hostname]:[port]``.
1922

20-
.. include:: /includes/fact-voting-node-sync-incompatibility.rst
2123

2224
Behavior
2325
--------

0 commit comments

Comments
 (0)