[SERVER-35159] Track transactions latency and add to serverStatus output Created: 22/May/18 Updated: 29/Oct/23 Resolved: 09/Aug/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Diagnostics, Replication |
| Affects Version/s: | None |
| Fix Version/s: | 4.1.2 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | William Schultz (Inactive) | Assignee: | Nathan Louie |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | global-txn-metrics | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||
| Sprint: | Repl 2018-07-16, Repl 2018-07-30, Repl 2018-08-13 | ||||||||||||
| Participants: | |||||||||||||
| Description |
|
Once the OperationLatencyHistogram supports tracking transactions latency, we need to update the appropriate histogram counters whenever a transaction commits or aborts. We can do this by calling Top::incrementGlobalLatencyStats on abort or commit, with the appropriate arguments to indicate this operation is a transaction, and the total duration of the transaction. The total transaction duration should be available by using the transaction startTime tracked in TxnStats on that transaction's session. Additionally, we will also need to update the OperationLatencyHistogram::append method so that it includes transaction latencies in a sub-document with key "transactions". We want the final serverStatus output to include the transaction latencies in the same format as the current read/write/command latencies, but in an opLatencies.transactions section. |
| Comments |
| Comment by Githook User [ 16/Aug/18 ] |
|
Author: {'username': 'nxlouie', 'email': 'nathan.louie@10gen.com', 'name': 'Nathan Louie'}Message: (cherry picked from commit e75f7fa2231cbd78d82923393de84d72702f9bcf) |
| Comment by Githook User [ 09/Aug/18 ] |
|
Author: {'name': 'Nathan Louie', 'email': 'nathan.louie@10gen.com', 'username': 'nxlouie'}Message: |
| Comment by William Schultz (Inactive) [ 09/Aug/18 ] |
|
Note: in this patch we are also ensuring that we use the same "now" time for recording various timing related transactions metrics. |
| Comment by Nathan Louie [ 12/Jul/18 ] |
|
kyle.suarez in
|