[SERVER-67990] Modify TestTimerElapsedAfterMultipleDetachAttach to run multiple times Created: 12/Jul/22  Updated: 29/Oct/23  Resolved: 26/Jul/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 6.1.0-rc0

Type: Bug Priority: Major - P3
Reporter: Yujin Kang Park Assignee: Yujin Kang Park
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Related
is related to SERVER-76700 Increase window of acceptable elapsed... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Execution Team 2022-07-25, Execution Team 2022-08-08
Participants:
Linked BF Score: 38

 Description   

PosixTimer relies on clock_gettime with CLOCK_THREAD_CPUTIME_ID to compute elapsed time. This is unreliable when the CPU on which the thread is executed changes, as the timer for that CPU will be different. This is fixed in glibc >= 2.4 running on kernel versions >= 2.6.12, but some evergreen instances still use older glibc versions. 

The CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID clocks are realized on many platforms using timers from the CPUs (TSC on i386, AR.ITC on Itanium). These registers may differ between CPUs and as a consequence these clocks may return bogus results if a process is migrated to another CPU.

We might try detecting this condition and retry the test. 

Retry X times and establish a failure rate threshold.



 Comments   
Comment by Githook User [ 26/Jul/22 ]

Author:

{'name': 'Yu Jin Kang Park', 'email': 'yujin.kang@mongodb.com', 'username': 'ykangpark'}

Message: SERVER-67990: TestTimerElapsedAfterMultipleDetachAttach change to multiple runs with fail threshold
Branch: master
https://github.com/mongodb/mongo/commit/519c7ea0dbf08591d967f1d1aa77ca77af257a7d

Generated at Thu Feb 08 06:09:35 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.