[SERVER-38659] Race condition in IsMasterIsFalseDuringStepdown unittest Created: 14/Dec/18  Updated: 29/Oct/23  Resolved: 18/Dec/18

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: 3.6.14, 4.1.7, 4.0.11

Type: Bug Priority: Major - P3
Reporter: A. Jesse Jiryu Davis Assignee: A. Jesse Jiryu Davis
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Related
is related to SERVER-37065 Report ismaster:false in isMaster com... Closed
Operating System: ALL
Backport Requested:
v4.0, v3.6
Sprint: Repl 2019-01-14
Participants:
Linked BF Score: 0

 Description   

There's a race in the test for "SERVER-37065 Report ismaster:false on learning of new term". The test asserts that "ismaster" is false right away when the primary learns of a new term, which is fine, and it also asserts that "secondary" is still false because the stepdown is incomplete. If the primary transitions to secondary quickly enough, the second assert fails.

Fix the race with the "blockHeartbeatStepdown" failpoint.



 Comments   
Comment by Githook User [ 02/Jul/19 ]

Author:

{'name': 'A. Jesse Jiryu Davis', 'email': 'jesse@mongodb.com', 'username': 'ajdavis'}

Message: SERVER-38659 Fix race in stepdown test
Branch: v3.6
https://github.com/mongodb/mongo/commit/4bc3e3ad0c4a9aea5afc4aac9b9400c8d85792de

Comment by Githook User [ 01/Jul/19 ]

Author:

{'name': 'A. Jesse Jiryu Davis', 'email': 'jesse@mongodb.com', 'username': 'ajdavis'}

Message: SERVER-38659 Fix race in stepdown test
Branch: v4.0
https://github.com/mongodb/mongo/commit/0cf58da55734ff8327e256f77ecc22a819ba313d

Comment by Githook User [ 18/Dec/18 ]

Author:

{'username': 'ajdavis', 'email': 'jesse@mongodb.com', 'name': 'A. Jesse Jiryu Davis'}

Message: SERVER-38659 Fix race in stepdown test
Branch: master
https://github.com/mongodb/mongo/commit/daf3d0485d6c595c26896512f6163c9e104d8f9e

Generated at Thu Feb 08 04:49:36 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.