Skip to content

Commit d8ec51d

Browse files
committed
DOCS-13315: 4.4 init sync operations restrictions
1 parent a4decf6 commit d8ec51d

18 files changed

+140
-0
lines changed

source/includes/extracts-4.4-changes.yaml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -479,4 +479,39 @@ content: |
479479
:ref:`forceJumbo <movechunk-forceJumbo>` to allow for the
480480
migration of chunks that are too large to move. The chunks may or
481481
may not be labeled :ref:`jumbo <jumbo-chunk>`.
482+
---
483+
ref: 4.4-changes-repl-state-restrictions
484+
content: |
485+
486+
Starting in MongoDB 4.4, to run on a replica set member, the
487+
following operations require the member to be in
488+
:replstate:`PRIMARY` or :replstate:`SECONDARY` state.
489+
490+
- :dbcommand:`listDatabases`
491+
- :dbcommand:`listCollections`
492+
- :dbcommand:`listIndexes`
493+
- :dbcommand:`distinct`
494+
- :dbcommand:`dbStats`
495+
- :dbcommand:`collStats`
496+
497+
If the member is in another state, such as :replstate:`STARTUP2`,
498+
the operation errors.
499+
500+
In previous versions, the operations can also be run when the member
501+
is in :replstate:`STARTUP2`. However, the operations wait
502+
until the member transitions to :replstate:`RECOVERING`.
503+
504+
---
505+
ref: 4.4-changes-repl-state-restrictions-operation
506+
content: |
507+
508+
Starting in MongoDB 4.4, to run on a replica set member,
509+
|operations| operations require the member to be in
510+
:replstate:`PRIMARY` or :replstate:`SECONDARY` state. If the member
511+
is in another state, such as :replstate:`STARTUP2`, the
512+
operation errors.
513+
514+
In previous versions, the operations can also be run when the member
515+
is in :replstate:`STARTUP2`. However, the operations wait
516+
until the member transitions to :replstate:`RECOVERING`.
482517
...

source/reference/command/collStats.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,12 @@ information on indexes currently being built. For details, see:
114114
- :data:`collStats.totalIndexSize`
115115
- :data:`collStats.indexSizes`
116116

117+
Replica Set Member State Restriction
118+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
119+
120+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
121+
122+
.. |operations| replace:: :dbcommand:`collStats`
117123

118124
Example
119125
-------

source/reference/command/dbStats.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,13 @@ Accuracy after Unexpected Shutdown
7676

7777
.. include:: /includes/fact-unexpected-shutdown-accuracy.rst
7878

79+
Replica Set Member State Restriction
80+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
81+
82+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
83+
84+
.. |operations| replace:: :dbcommand:`dbStats`
85+
7986
.. _dbstats-output:
8087

8188
Output

source/reference/command/distinct.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,12 @@ Client Disconnection
143143

144144
.. include:: /includes/extracts/4.2-changes-disconnect.rst
145145

146+
Replica Set Member State Restriction
147+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
148+
149+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
150+
151+
.. |operations| replace:: :dbcommand:`distinct`
146152

147153
Examples
148154
--------

source/reference/command/listCollections.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,13 @@ Client Disconnection
150150

151151
.. |operation| replace:: :dbcommand:`listCollections`
152152

153+
Replica Set Member State Restriction
154+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
155+
156+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
157+
158+
.. |operations| replace:: :dbcommand:`listCollections`
159+
153160
Required Access
154161
---------------
155162

source/reference/command/listDatabases.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,15 @@ Client Disconnection
194194

195195
.. |operation| replace:: :dbcommand:`listDatabases`
196196

197+
198+
Replica Set Member State Restriction
199+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
200+
201+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
202+
203+
.. |operations| replace:: :dbcommand:`listDatabases`
204+
205+
197206
Examples
198207
--------
199208

source/reference/command/listIndexes.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,13 @@ Client Disconnection
7474

7575
.. include:: /includes/extracts/4.2-changes-disconnect.rst
7676

77+
Replica Set Member State Restriction
78+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
79+
80+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
81+
82+
.. |operations| replace:: :dbcommand:`listIndexes`
83+
7784
Output
7885
------
7986

source/reference/method/db.collection.dataSize.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,9 @@ db.collection.dataSize()
2525
This method provides a wrapper around the :data:`~collStats.size`
2626
output of the :dbcommand:`collStats` (i.e.
2727
:method:`db.collection.stats()`) command.
28+
29+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
30+
31+
.. |operations| replace:: :dbcommand:`collStats`
32+
33+

source/reference/method/db.collection.distinct.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,12 @@ Client Disconnection
131131

132132
.. include:: /includes/extracts/4.2-changes-disconnect.rst
133133

134+
Replica Set Member State Restriction
135+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
136+
137+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
138+
139+
.. |operations| replace:: :dbcommand:`distinct`
134140

135141
Examples
136142
--------

source/reference/method/db.collection.getIndexes.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,13 @@ Client Disconnection
4141

4242
.. include:: /includes/extracts/4.2-changes-disconnect.rst
4343

44+
Replica Set Member State Restriction
45+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
46+
47+
.. include:: /includes/extracts/4.4-changes-repl-state-restrictions-operation.rst
48+
49+
.. |operations| replace:: :dbcommand:`listIndexes`
50+
4451
Required Access
4552
---------------
4653

0 commit comments

Comments
 (0)