Skip to content

Commit fe5e46d

Browse files
author
Ed Costello
committed
DOCS-979 updated after finding a comment from Randall
Randall commented in email: _active is probably more correctly thought of as _started -- things remain active (currently) even when they're yielded. At least in my limited test and understanding of the execution logic. _active only goes back to false during a reset/when the op is done. I checked in the source and _active will only be set to false if the op has not started or the op has completed, otherwise it is always true even if the op has yielded to another op.
1 parent 8bb2f61 commit fe5e46d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

source/reference/current-op.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,8 +99,10 @@ depending on the kind of operation and its state.
9999

100100
.. data:: currentOp.active
101101

102-
A boolean value, that is ``true`` if the operation is currently running
102+
A boolean value, that is ``true`` if the operation has started
103103
or ``false`` if the operation is queued and waiting for a lock to run.
104+
:data:`~currentOp.active` may be ``true`` even if the operation has
105+
yielded to another operation.
104106

105107
.. data:: currentOp.secs_running
106108

0 commit comments

Comments
 (0)