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

Connpool HostTimeout races with callback lock acquire/release

    • Fully Compatible
    • ALL
    • v3.4, v3.2
    • Hide

      Add a small timeout before any call to lock() in connection_pool.cpp

      Show
      Add a small timeout before any call to lock() in connection_pool.cpp
    • Platforms 2017-10-23, Platforms 2017-11-13
    • 0

      The executor connection pool host timeout is racy with respect to other code that's unlocked the parent mutex to allow for callback execution.

      While effort was spent to protect against background threads with active requests and those participating in refresh, after those tasks have been executed we race with callbacks in how quickly they can return. When we lose that race, we destroy the specific pool out from under those callbacks.

            Assignee:
            mira.carey@mongodb.com Mira Carey
            Reporter:
            mira.carey@mongodb.com Mira Carey
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: