Skip to content

Commit 7be30ee

Browse files
(DOCSP-26200): queryStats aggregation stage (#4524)
* (DOCSP-26200): queryStats aggregation stage * WIP * WIP * WIP * Remove accidental file * add TODO * add missing ref * formatting * WIP * WIP * WIP * wording * WIP * edits * add examples * try to fix table format * add transformed example * remove TODO * more table formatting * add atlas data collection * table formatting * clarity * add more context for data collection * table formatting * wording tweaks * address review comments * formatting * use simplified examples * add input/output * edits * add link to transformed example * spacing * edits * address review comments * fix incomplete sentence * rework transformation section * edits * fix collation link formatting * change wording for output fields * edit glossary * more edits * remove glossary entry * formatting * edits * Address review feedback * wording * review edit * wording * WIP review edits * remove Atlas data collection info * (DOCSP-33347): Re-add Atlas data collection info * typo * minimalism * typo * clarity * remove Atlas data collection info * edits * (DOCSP-33347): Re-add Atlas data collection info * add find queryShape properties * change case * formatting * abstracted > normalized consistency * clarify privilege * address review comments * review edits
1 parent cb0b2fd commit 7be30ee

File tree

12 files changed

+985
-4
lines changed

12 files changed

+985
-4
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Returns runtime statistics for recorded queries.
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
.. warning::
2+
3+
The ``$queryStats`` aggregation stage is unsupported and is not
4+
guaranteed to be stable in a future release. Don't build
5+
functionality that relies on a specific output format of this stage,
6+
since the output may change in a future release.

source/includes/extracts-agg-stages.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,12 @@ content: |
161161
162162
See also :pipeline:`$unset` for removing existing fields.
163163
164+
* - :pipeline:`$queryStats`
165+
166+
- .. include:: /includes/aggregation/queryStats/description.rst
167+
168+
.. include:: /includes/aggregation/queryStats/unsupported-warning.rst
169+
164170
* - :pipeline:`$redact`
165171
166172
- Reshapes each document in the stream by restricting the

source/reference/method/cursor.allowPartialResults.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
.. _cursor-allowPartialResults:
2+
13
============================
24
cursor.allowPartialResults()
35
============================
@@ -30,5 +32,3 @@ syntax:
3032
.. code-block:: javascript
3133

3234
db.collection.find(<query>, <projection>).allowPartialResults()
33-
34-

source/reference/method/cursor.batchSize.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
.. _cursor-batchSize:
2+
13
==================
24
cursor.batchSize()
35
==================

source/reference/method/cursor.maxTimeMS.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
.. _cursor-maxTimeMS:
2+
13
==================
24
cursor.maxTimeMS()
35
==================
@@ -146,4 +148,3 @@ Examples
146148
.. code-block:: javascript
147149

148150
db.collection.find({description: /August [0-9]+, 1969/}).maxTimeMS(50)
149-

source/reference/method/cursor.noCursorTimeout.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
.. _cursor-noCursorTimeout:
2+
13
========================
24
cursor.noCursorTimeout()
35
========================

source/reference/operator/aggregation-pipeline.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,10 @@ Alphabetical Listing of Stages
255255
- Reshapes each document in the stream, such as by adding new fields or
256256
removing existing fields. For each input document, outputs one
257257
document.
258-
258+
259+
* - :pipeline:`$queryStats`
260+
261+
- .. include:: /includes/aggregation/queryStats/description.rst
259262

260263
* - :pipeline:`$redact`
261264

@@ -417,6 +420,7 @@ Alphabetical Listing of Stages
417420
/reference/operator/aggregation/out
418421
/reference/operator/aggregation/planCacheStats
419422
/reference/operator/aggregation/project
423+
/reference/operator/aggregation/queryStats
420424
/reference/operator/aggregation/redact
421425
/reference/operator/aggregation/replaceRoot
422426
/reference/operator/aggregation/replaceWith

0 commit comments

Comments
 (0)