[SERVER-51601] Make OperationCPUTimer initializer more resilient Created: 14/Oct/20  Updated: 29/Oct/23  Resolved: 19/Nov/20

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

Type: Improvement Priority: Major - P3
Reporter: Amirsaman Memaripour Assignee: Amirsaman Memaripour
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-47446 Measure cpu time taken by operations Closed
Backwards Compatibility: Fully Compatible
Sprint: Service arch 2020-11-02, Service arch 2020-11-16, Service arch 2020-11-30
Participants:

 Description   

Currently, OperationCPUTimer throws an exception if it cannot get the time for the current thread on Linux (see here).

Instead, it should check if clock_gettime(CLOCK_THREAD_CPUTIME_ID, &t) is available on initialization (here) and terminate if subsequent calls to _getThreadTime() fail. 



 Comments   
Comment by Githook User [ 19/Nov/20 ]

Author:

{'name': 'Amirsaman Memaripour', 'email': 'amirsaman.memaripour@mongodb.com', 'username': 'samanca'}

Message: SERVER-51601 Make OperationCPUTimer initializer more resilient
Branch: master
https://github.com/mongodb/mongo/commit/4739fb232284a655f0ae89c9a43490ed2219cb5e

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