Skip to content

DOCS-14152 Add server status cursor has more than one batch #5112

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions source/reference/command/serverStatus.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4619,6 +4619,12 @@ metrics
"wtimeouts" : NumberLong(<num>)
}
},
"mongos" : {
"cursor" : {
"moreThanOneBatch" : NumberLong(<num>),
"totalOpened" : NumberLong(<num>)
}
},
"operation" : {
"scanAndOrder" : NumberLong(<num>),
"writeConflicts" : NumberLong(<num>)
Expand Down Expand Up @@ -4879,7 +4885,33 @@ metrics

Number of times a non-``clientSupplied`` write concern timed out.

.. _server-status-metrics-mongos:

.. serverstatus:: metrics.mongos

A document that contains metrics about :binary:`~bin.mongos`.

.. serverstatus:: metrics.mongos.cursor

A document that contains metrics for cursors used by
:binary:`~bin.mongos`.

.. serverstatus:: metrics.mongos.cursor.moreThanOneBatch

The total number of cursors that have returned more than one batch
since :binary:`~bin.mongos` started. Additional batches are retrieved
using the :dbcommand:`getMore` command.

.. versionadded:: 5.0

.. serverstatus:: metrics.mongos.cursor.totalOpened

The total number of cursors that have been opened since
:binary:`~bin.mongos` started, including cursors currently open.
Differs from :serverstatus:`metrics.cursor.open.total`, which is the
number of currently open cursors only.

.. versionadded:: 5.0

.. serverstatus:: metrics.operation

Expand Down
17 changes: 11 additions & 6 deletions source/release-notes/5.0.txt
Original file line number Diff line number Diff line change
Expand Up @@ -371,12 +371,17 @@ output:
Cursor Metrics
.. list-table::

* - | :serverstatus:`metrics.cursor.moreThanOneBatch`, which
reports the total number of cursors that have returned
more than one batch (additional batches are retrieved
using the :dbcommand:`getMore` command)
| :serverstatus:`metrics.cursor.totalOpened`, which reports
the total number of cursors that have been opened
* - | :serverstatus:`metrics.cursor.moreThanOneBatch` and
:serverstatus:`metrics.mongos.cursor.moreThanOneBatch`,
which report the total number of cursors that have
returned more than one batch on :binary:`~bin.mongod` and
:binary:`~bin.mongos` respectively (additional batches
are retrieved using the :dbcommand:`getMore` command)
| :serverstatus:`metrics.cursor.totalOpened` and
:serverstatus:`metrics.mongos.cursor.totalOpened`, which
report the total number of cursors that have been opened
on :binary:`~bin.mongod` and :binary:`~bin.mongos`
respectively

.. _5.0-rel-notes-shell:

Expand Down