[SERVER-57131] Fix trivial race in topology_listener_test Created: 21/May/21  Updated: 29/Oct/23  Resolved: 24/May/21

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 5.1.0-rc0, 5.0.5

Type: Bug Priority: Major - P3
Reporter: Andrew Shuvalov (Inactive) Assignee: Andrew Shuvalov (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v5.0
Participants:
Linked BF Score: 135

 Description   

There is a small race probability in the test that after `l1->hasPingResponse()` is true the use count is still 0. Just refactor the loop.



 Comments   
Comment by Githook User [ 29/Oct/21 ]

Author:

{'name': 'Andrew Shuvalov', 'email': 'andrew.shuvalov@mongodb.com', 'username': 'shuvalov-mdb'}

Message: SERVER-57131: BACKPORT-11036 Fix trivial race in topology_listener_test
Branch: v5.0
https://github.com/mongodb/mongo/commit/f5c80c9add53d72bacafde9a394b2f61777a6430

Comment by Githook User [ 24/May/21 ]

Author:

{'name': 'Andrew Shuvalov', 'email': 'andrew.shuvalov@mongodb.com', 'username': 'shuvalov-mdb'}

Message: SERVER-57131: Fix trivial race in topology_listener_test
Branch: master
https://github.com/mongodb/mongo/commit/4d720b2eac01fd5044ae114690384c4413ed92b9

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