[SERVER-45377] Add methods to globally disable and re-enable hang analyzer in tests Created: 06/Jan/20  Updated: 29/Oct/23  Resolved: 03/Feb/20

Status: Closed
Project: Core Server
Component/s: Replication, Testing Infrastructure
Affects Version/s: None
Fix Version/s: 4.3.4

Type: Improvement Priority: Major - P3
Reporter: Vesselina Ratcheva (Inactive) Assignee: Robert Guo (Inactive)
Resolution: Fixed Votes: 0
Labels: tig-hanganalyzer
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-45150 Fix two repl tests to not call hang a... Closed
Backwards Compatibility: Fully Compatible
Sprint: STM 2020-01-23, STM 2020-02-10
Participants:
Story Points: 1

 Description   

While the passing the 'runHangAnalyzer=false' argument to assert.soon works well in mosts tests, there are a few replica set tests that expect throws of assert.soon calls located several functions deep into the ReplSetTest fixture.

In such cases, it would be cleaner if we had global enable/disable methods for the hang analyzer and let tests wrap an enable/disable pair around the places where they expect assert.soon to fail, to be used as such:

...
hangAnalyzer.disable();
 
// This ultimately triggers an assert.soon failure.
timeoutExpectedByTest();
 
hangAnalyzer.enable();
...



 Comments   
Comment by Githook User [ 31/Jan/20 ]

Author:

{'name': 'Robert Guo', 'email': 'robert.guo@mongodb.com'}

Message: SERVER-45377 add global option to enable and disable shell hang analyzer
Branch: master
https://github.com/mongodb/mongo/commit/109047bc5402ffe2b2ada07e677e9699cd74a76e

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