[SERVER-18083] Add serverStatus performance counters for write concern Created: 16/Apr/15  Updated: 18/Nov/16  Resolved: 19/Apr/15

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: 3.0.2
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Bruce Lucas (Inactive) Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-18067 Add the time spent waiting for write ... Closed
is related to SERVER-18134 rename serverStatus metrics.getLastEr... Closed
Participants:
Case:

 Description   

It would be useful for diagnosing performance issues related to write concern to have serverStatus performance counters that record

  • the cumulative number of times an operation waited for write concern
  • the total amount of time waited

This is the performance counter complement to SERVER-18067.



 Comments   
Comment by Daniel Pasette (Inactive) [ 19/Apr/15 ]

Sounds like a good idea to rename this field in serverStatus and update the docs. I don't believe many users are relying on the name of this sub-section, so shouldn't be disruptive to users looking for the old name.

Comment by Bruce Lucas (Inactive) [ 17/Apr/15 ]

Thanks! I think I missed it because it appears getLastError, which is a legacy artifact; the app I was debugging was using bulk writes. Would it make sense to rename this section, e.g. "writeConcern"?

Comment by Daniel Pasette (Inactive) [ 17/Apr/15 ]

I think the info you're looking for is already present and has been there since v2.4.

rs1:PRIMARY> db.serverStatus()
        ....
	"metrics" : {
        .....
		"getLastError" : {
			"wtime" : {
				"num" : 0,
				"totalMillis" : 0
			},
			"wtimeouts" : NumberLong(0)
		},

Generated at Thu Feb 08 03:46:31 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.