Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-40054

Destroying an AsyncWorkScheduler which has not been shut down can block forever

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.1.9
    • Affects Version/s: None
    • Component/s: Internal Code
    • None
    • Fully Compatible
    • ALL
    • Sharding 2019-04-08
    • 22

      The destructor of AsyncWorkScheduler waits for all the scheduled activity to complete. However, the condition variable indicating that is only signaled if shutdown has been called previously.

      Because of this, if it so happens that at destruction time the last asynchronous activity of a successfully completed asynchronous work hadn't unregistered itself, the destructor can block forever, even though there are no active tasks.

            Assignee:
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Reporter:
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: