Skip to content

Commit 79f3a59

Browse files
jason-price-mongodbjason-price-mongodb
andauthored
Docs 15705 session workflow log (#2293)
* DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log * DOCS-15705-session-workflow-log Co-authored-by: jason-price-mongodb <[email protected]>
1 parent aaf3c20 commit 79f3a59

File tree

3 files changed

+86
-3
lines changed

3 files changed

+86
-3
lines changed

source/reference/command/profile.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,6 @@ The command has the following syntax:
8181
}
8282
)
8383

84-
.. _slowms-threshold-option:
85-
8684
Command Fields
8785
--------------
8886

@@ -109,7 +107,9 @@ The command takes the following fields:
109107

110108
* - ``slowms``
111109
- int
112-
- Optional. Default: 100
110+
- .. _slowms-threshold-option:
111+
112+
Optional. Default: 100
113113

114114
.. include:: /includes/dbcommand-slowms-definition.rst
115115

source/reference/log-messages.txt

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1586,3 +1586,78 @@ authorization cache.
15861586
"userCacheWaitTimeMicros": 508
15871587
},
15881588

1589+
.. _log-messages-session-workflow-example:
1590+
1591+
Session Workflow Log Message
1592+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1593+
1594+
Starting in MongoDB 6.3, a message is added to the log if the time to
1595+
send an operation response exceeds the :ref:`slowms threshold option
1596+
<slowms-threshold-option>`.
1597+
1598+
The message is known as a session workflow log message and contains
1599+
various times to perform an operation in a database session.
1600+
1601+
Example session workflow log message:
1602+
1603+
.. code-block:: javascript
1604+
:copyable: false
1605+
1606+
{
1607+
"t": {
1608+
"$date": "2022-12-14T17:22:44.233+00:00"
1609+
},
1610+
"s": "I",
1611+
"c": "EXECUTOR",
1612+
"id": 6983000,
1613+
"ctx": "conn1",
1614+
"msg": "Slow network response send time",
1615+
"attr": {
1616+
"elapsed": {
1617+
"totalMillis": 109,
1618+
"activeMillis": 30,
1619+
"receiveWorkMillis": 2,
1620+
"processWorkMillis": 10,
1621+
"sendResponseMillis": 22,
1622+
"yieldMillis": 15,
1623+
"finalizeMillis": 30
1624+
}
1625+
}
1626+
}
1627+
1628+
The times are in milliseconds.
1629+
1630+
A session workflow message is added to the log if ``sendResponseMillis``
1631+
exceeds the :ref:`slowms threshold option <slowms-threshold-option>`.
1632+
1633+
.. list-table::
1634+
:header-rows: 1
1635+
:widths: 15 85
1636+
1637+
* - Field
1638+
- Description
1639+
1640+
* - ``totalMillis``
1641+
- Total time to perform the operation in the session, which
1642+
includes the time spent waiting for a message to be received.
1643+
1644+
* - ``activeMillis``
1645+
- Time between receiving a message and completing the operation
1646+
associated with that message. Time includes sending a response
1647+
and performing any clean up.
1648+
1649+
* - ``receivedWorkMillis``
1650+
- Time to receive the operation information over the network.
1651+
1652+
* - ``processWorkMillis``
1653+
- Time to process the operation and create the response.
1654+
1655+
* - ``sendResponseMillis``
1656+
- Time to send the response.
1657+
1658+
* - ``yieldMillis``
1659+
- Time between releasing the worker thread and the thread being
1660+
used again.
1661+
1662+
* - ``finalize``
1663+
- Time to end and close the session workflow.

source/release-notes/6.3.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,14 @@ these output changes:
6565
range.
6666
Total number of connection requests for all time ranges.
6767

68+
Session Workflow Log Message
69+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
70+
71+
Starting in MongoDB 6.3, a message is added to the log if the time to
72+
send an operation response exceeds the :ref:`slowms threshold option
73+
<slowms-threshold-option>`. For details, see
74+
:ref:`log-messages-session-workflow-example`.
75+
6876
Server Parameters
6977
-----------------
7078

0 commit comments

Comments
 (0)