[SERVER-26341] TaskRunner destroyed prior to task return Created: 26/Sep/16  Updated: 06/Dec/22  Resolved: 26/Sep/16

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

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

Issue Links:
Depends
is depended on by SERVER-24032 When processing createIndexes (on V2 ... Closed
Duplicate
duplicates SERVER-26179 Do not join the TaskRunner within a r... Closed
Assigned Teams:
Replication
Operating System: ALL
Steps To Reproduce:

Reproduced by return of a non-OK status from loader->init()

Participants:

 Description   

See https://github.com/mongodb/mongo/blob/r3.3.14/src/mongo/db/repl/storage_interface_impl.cpp#L250-L291

A task runner is created that runs a synchronous task to clone a collection. During execution the task runner ownership is moved to the CollectionBulkloaderImpl ('loader') object on line 285.

If the call to loader->init() fails on line 289, then the runner will be destroyed, prior to returning from the task. This appears to leave the TaskRunner::runSynchronousTask() call/thread blocked, waiting on its 'waitTillDoneCond' condition variable.



 Comments   
Comment by Scott Hernandez (Inactive) [ 26/Sep/16 ]

Looks like SERVER-26179.

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