[SERVER-40499] ReplicationCoordinatorImpl::_handleHeartbeatResponse should check for cancelation before taking mutex Created: 05/Apr/19  Updated: 06/Dec/22  Resolved: 15/Apr/19

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

Type: Bug Priority: Major - P3
Reporter: Spencer Jackson Assignee: Backlog - Replication Team
Resolution: Duplicate Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates SERVER-40633 Audit all uses of _replExecutor and c... Closed
Related
is related to SERVER-39965 Make OutOfLineExecutor return a Statu... Closed
Assigned Teams:
Replication
Operating System: ALL
Sprint: Repl 2019-05-06
Participants:
Linked BF Score: 24

 Description   

Per ben.caimano's recent email, task executors are now more aggressive about running callbacks on callers' threads. This means that callbacks should check their provided status argument for whether they're on the caller's thread.

_handleHeartbeatResponse takes the same mutex that its caller takes. If it runs on the caller's thread, it will deadlock with itself.



 Comments   
Comment by Gregory McKeon (Inactive) [ 15/Apr/19 ]

Per siyuan.zhou, this is a dupe.

Comment by Gregory McKeon (Inactive) [ 08/Apr/19 ]

We'll have someone follow up with Ben to understand the implications of his changes both here and more generally and report back.

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