@@ -1736,7 +1736,8 @@ metrics
17361736 reconfig : {
17371737 numAutoReconfigsForRemovalOfNewlyAddedFields : Long("<num>")
17381738 },
1739- stepDown : {
1739+ stateTransition : {
1740+ lastStateTransition : <string>,
17401741 userOperationsKilled : Long("<num>"),
17411742 userOperationsRunning : Long("<num>")
17421743 },
@@ -2543,26 +2544,52 @@ metrics
25432544
25442545 .. versionadded:: 5.0
25452546
2546- .. serverstatus:: metrics.repl.stepDown
2547+ .. serverstatus:: metrics.repl.stateTransition
25472548
2548- Information on user operations that were running when the
2549- :binary:`~bin.mongod` stepped down.
2549+ Information on user operations when the member undergoes one of the
2550+ following transitions that can stop user operations:
25502551
2551- .. versionadded:: 4.2
2552+ - The member steps up to become a primary.
25522553
2553- .. serverstatus:: metrics.repl.stepDown.userOperationsKilled
2554+ - The member steps down to become a secondary.
25542555
2555- The number of user operations killed when the :binary:`~bin.mongod`
2556- stepped down.
2556+ - The member is actively performing a rollback.
25572557
2558- .. versionadded :: 4.2
2558+ .. serverstatus :: metrics.repl.stateTransition.lastStateTransition
25592559
2560- .. serverstatus:: metrics.repl.stepDown.userOperationsRunning
2560+ The transition being reported:
25612561
2562- The number of user operations that remained running when the
2563- :binary:`~bin.mongod` stepped down.
2562+ .. list-table::
2563+ :widths: 20 80
2564+ :header-rows: 1
25642565
2565- .. versionadded:: 4.2
2566+ * - State Change
2567+ - Description
2568+
2569+ * - ``"stepUp"``
2570+
2571+ - The member steps up to become a primary.
2572+
2573+ * - ``"stepDown"``
2574+ - The member steps down to become a secondary.
2575+
2576+ * - ``"rollback"``
2577+
2578+ - The member is actively performing a rollback.
2579+
2580+ * - ``""``
2581+
2582+ - The member has not undergone any state changes.
2583+
2584+ .. serverstatus:: metrics.repl.stateTransition.userOperationsKilled
2585+
2586+ The number of user operations stopped during the
2587+ :binary:`~bin.mongod` instance's state change.
2588+
2589+ .. serverstatus:: metrics.repl.stateTransition.userOperationsRunning
2590+
2591+ The number of user operations that remained running during the
2592+ ``mongod`` instance's state change.
25662593
25672594.. serverstatus:: metrics.repl.syncSource
25682595
0 commit comments