[SERVER-55556] server metric to record per-operation units written (includes both document and index bytes) Created: 26/Mar/21  Updated: 29/Oct/23  Resolved: 03/May/21

Status: Closed
Project: Core Server
Component/s: Internal Code
Affects Version/s: None
Fix Version/s: 4.9.0-rc1, 5.0.0-rc0

Type: Task Priority: Major - P3
Reporter: Eric Milkie Assignee: Eric Milkie
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Related
is related to SERVER-57150 update architecture guide for total u... Closed
Backwards Compatibility: Fully Compatible
Backport Requested:
v4.9
Sprint: Elastic 2021-03-29, Elastic 2021-04-05, Elastic 2021-04-19, Elastic 2021-04-26, Elastic 2021-05-03, Elastic 2021-05-10
Participants:

 Description   

Create a server metric to represent the number of bytes written to both data tables and index tables, quantized to a configureable Unit size.

Currently we have similar metrics that only use data table bytes (docUnitsRead/docUnitsWritten), or index table bytes (idxEntryBytesRead/idxEntryBytesWritten).

Proposal is to add a new metric:
totalUnitsWritten

and one new configuration parameter, totalUnitWriteSizeBytes

Additionally, a timestamp field "localTime" will be added to each database BSONArray in the output for the operationMetrics aggregation stage, as per InTel request.



 Comments   
Comment by Githook User [ 03/May/21 ]

Author:

{'name': 'Eric Milkie', 'email': 'milkie@10gen.com', 'username': 'milkie'}

Message: SERVER-55556 add new totalUnitsWritten metric; add new localTime field to operationMetrics output

totalUnitsWritten is a metric that represents the number of bytes written to a document plus any index entries that follow, prior to writing another document; these bytes are then translated into Units as per the totalUnitWriteSizeBytes parameter.
Additionally, a new field localTime will now appear in every BSONArray (per database) included in the $operationMetrics aggregation stage

(cherry picked from commit 960f5deb14520af3076c9164fbf8b3cbcca0560f)
Branch: v4.9
https://github.com/mongodb/mongo/commit/a58447691485ec04d39d7b9d42dc28cd6900da6c

Comment by Githook User [ 03/May/21 ]

Author:

{'name': 'Eric Milkie', 'email': 'milkie@10gen.com', 'username': 'milkie'}

Message: SERVER-55556 add new totalUnitsWritten metric; add new localTime field to operationMetrics output

totalUnitsWritten is a metric that represents the number of bytes written to a document plus any index entries that follow, prior to writing another document; these bytes are then translated into Units as per the totalUnitWriteSizeBytes parameter.
Additionally, a new field localTime will now appear in every BSONArray (per database) included in the $operationMetrics aggregation stage
Branch: master
https://github.com/mongodb/mongo/commit/960f5deb14520af3076c9164fbf8b3cbcca0560f

Comment by Eric Milkie [ 30/Mar/21 ]

Yes, I expect so.

Comment by Vladimir Isakov (Inactive) [ 30/Mar/21 ]

milkie would this server time be the same across all db documents in the operation metrics response cursor?

Comment by Eric Milkie [ 29/Mar/21 ]

There is also a request to add the current server time to each metrics document returned by the agg stage.

Generated at Thu Feb 08 05:36:48 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.