diff --git a/source/reference/command/currentOp.txt b/source/reference/command/currentOp.txt index 8b0b3784b6b..8c0f3bb1b06 100644 --- a/source/reference/command/currentOp.txt +++ b/source/reference/command/currentOp.txt @@ -1134,6 +1134,110 @@ Output Fields .. versionadded:: 5.0 +.. data:: currentOp.approxDocumentsToCopy + + The approximate number of documents to be copied from the donor + shards to the recipient shards during the resharding operation. This + number is an estimate that is set at the beginning of the resharding + operation and does not change after it has been set. The number is + set to 0 when a new resharding operation starts. It is + possible for ``$currentOp.documentsCopied`` and + ``$currentOp.bytesCopied`` to end up exceeding + ``$currentOp.approxDocumentsToCopy`` and + ``$currentOp.approxBytesToCopy``, respectively, if + the post-resharding data distribution is not perfectly uniform. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: currentOp.documentsCopied + + The number of documents copied form donor shards to recipient shards + during the resharding operation. The number is set to 0 when a new + resharding operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: currentOp.approxBytesToCopy + + The approximate number of bytes to be copied from the donor shards to + the recipient shards during the resharding operation. This number is + an estimate that is set at the beginning of the resharding operation + and does not change after it has been set. The number is set to 0 + when a new resharding operation starts. It is possible for + ``$currentOp.documentsCopied`` and ``$currentOp.bytesCopied`` to end + up exceeding ``$currentOp.approxDocumentsToCopy`` and + ``$currentOp.approxBytesToCopy``, respectively, if the + post-resharding data distribution is not perfectly uniform. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: currentOp.bytesCopied + + The number of bytes copied from donor shards to recipient shards + during the resharding operation. The number is set to 0 when a new + resharding operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: currentOp.totalCopyTimeElapsed + + The total elapsed time, in seconds, for ongoing data copy tasks from + donor shards to recipient shards for the current resharding + operation. The time is set to 0 when a new resharding operation + starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: currentOp.oplogEntriesFetched + + The number of entries fetched from the :term:`oplog` for the current + resharding operation. The number is set to 0 when a new resharding + operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: currentOp.oplogEntriesApplied + + The number of entries applied to the :term:`oplog` for the current + resharding operation. The number is set to 0 when a new resharding + operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: currentOp.totalApplyTimeElapsed + + The total elapsed time, in seconds, for the apply step of the + current resharding operation. In the apply step, recipient shards + apply :term:`oplog` entries to modify their data based on new + incoming writes from donor shards. The time is set to 0 when a new + resharding operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + .. data:: currentOp.countWritesDuringCriticalSection The number of writes perfomed in the critical section for the current @@ -1207,6 +1311,59 @@ Output Fields .. versionadded:: 5.0 +.. data:: currentOp.recipientState + + The current state of a recipient shard for a resharding operation. + The state is set to ``unused`` when a new resharding operation + starts. + + Only present on a donor shard when a resharding operation is taking + place. + + .. list-table:: + :widths: 20 80 + :header-rows: 1 + + * - State + - Description + + * - ``unused`` + - The resharding operation is about to start. + + * - ``awaiting-fetch-timestamp`` + - The recipient shard is waiting for the donor shards to be + prepared to donate their data. + + * - ``creating-collection`` + - The recipient shard is creating the new sharded collection. + + * - ``cloning`` + - The recipient shard is receiving data from the donor shards. + + * - ``applying`` + - The recipient shard is applying :term:`oplog` entries to + modify its copy of the data based on the new incoming writes + from donor shards. The recipient shard data is not yet + consistent with the donor shard data. + + * - ``steady-state`` + - The recipient shard data is consistent with the donor shard + data. + + * - ``strict-consistency`` + - The recipient shard has all data changes. + + * - ``renaming`` + - The recipient shard renames the new sharded collection. + + * - ``done`` + - The resharding operation is complete. + + * - ``error`` + - An error occurred during the resharding operation. + + .. versionadded:: 5.0 + .. data:: currentOp.coordinatorState The state of the resharding coordinator for the current resharding @@ -1306,4 +1463,4 @@ Output Fields * - ``canceled`` - The resharding operation was canceled. - .. versionadded:: 5.0 \ No newline at end of file + .. versionadded:: 5.0 diff --git a/source/reference/operator/aggregation/currentOp.txt b/source/reference/operator/aggregation/currentOp.txt index 013596b5628..287d8379802 100644 --- a/source/reference/operator/aggregation/currentOp.txt +++ b/source/reference/operator/aggregation/currentOp.txt @@ -1591,6 +1591,110 @@ relevant for the operation: .. versionadded:: 5.0 +.. data:: $currentOp.approxDocumentsToCopy + + The approximate number of documents to be copied from the donor + shards to the recipient shards during the resharding operation. This + number is an estimate that is set at the beginning of the resharding + operation and does not change after it has been set. The number is + set to 0 when a new resharding operation starts. It is + possible for ``$currentOp.documentsCopied`` and + ``$currentOp.bytesCopied`` to end up exceeding + ``$currentOp.approxDocumentsToCopy`` and + ``$currentOp.approxBytesToCopy``, respectively, if + the post-resharding data distribution is not perfectly uniform. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: $currentOp.documentsCopied + + The number of documents copied form donor shards to recipient shards + during the resharding operation. The number is set to 0 when a new + resharding operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: $currentOp.approxBytesToCopy + + The approximate number of bytes to be copied from the donor shards to + the recipient shards during the resharding operation. This number is + an estimate that is set at the beginning of the resharding operation + and does not change after it has been set. The number is set to 0 + when a new resharding operation starts. It is possible for + ``$currentOp.documentsCopied`` and ``$currentOp.bytesCopied`` to end + up exceeding ``$currentOp.approxDocumentsToCopy`` and + ``$currentOp.approxBytesToCopy``, respectively, if the + post-resharding data distribution is not perfectly uniform. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: $currentOp.bytesCopied + + The number of bytes copied from donor shards to recipient shards + during the resharding operation. The number is set to 0 when a new + resharding operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: $currentOp.totalCopyTimeElapsed + + The total elapsed time, in seconds, for ongoing data copy tasks from + donor shards to recipient shards for the current resharding + operation. The time is set to 0 when a new resharding operation + starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: $currentOp.oplogEntriesFetched + + The number of entries fetched from the :term:`oplog` for the current + resharding operation. The number is set to 0 when a new resharding + operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: $currentOp.oplogEntriesApplied + + The number of entries applied to the :term:`oplog` for the current + resharding operation. The number is set to 0 when a new resharding + operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + +.. data:: $currentOp.totalApplyTimeElapsed + + The total elapsed time, in seconds, for the apply step of the + current resharding operation. In the apply step, recipient shards + apply :term:`oplog` entries to modify their data based on new + incoming writes from donor shards. The time is set to 0 when a new + resharding operation starts. + + Only present on a recipient shard when a resharding operation is + taking place. + + .. versionadded:: 5.0 + .. data:: $currentOp.countWritesDuringCriticalSection The number of writes perfomed in the critical section for the current @@ -1664,6 +1768,59 @@ relevant for the operation: .. versionadded:: 5.0 +.. data:: $currentOp.recipientState + + The current state of a recipient shard for a resharding operation. + The state is set to ``unused`` when a new resharding operation + starts. + + Only present on a donor shard when a resharding operation is taking + place. + + .. list-table:: + :widths: 20 80 + :header-rows: 1 + + * - State + - Description + + * - ``unused`` + - The resharding operation is about to start. + + * - ``awaiting-fetch-timestamp`` + - The recipient shard is waiting for the donor shards to be + prepared to donate their data. + + * - ``creating-collection`` + - The recipient shard is creating the new sharded collection. + + * - ``cloning`` + - The recipient shard is receiving data from the donor shards. + + * - ``applying`` + - The recipient shard is applying :term:`oplog` entries to + modify its copy of the data based on the new incoming writes + from donor shards. The recipient shard data is not yet + consistent with the donor shard data. + + * - ``steady-state`` + - The recipient shard data is consistent with the donor shard + data. + + * - ``strict-consistency`` + - The recipient shard has all data changes. + + * - ``renaming`` + - The recipient shard renames the new sharded collection. + + * - ``done`` + - The resharding operation is complete. + + * - ``error`` + - An error occurred during the resharding operation. + + .. versionadded:: 5.0 + .. data:: $currentOp.coordinatorState The state of the resharding coordinator for the current resharding