Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-2491

The dhandle close_lock isn't valuable at the moment

    • Type: Icon: Improvement Improvement
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None

      The only place we currently take the WT_DHANDLE::close_lock is in __wt_conn_btree_sync_and_close. It used to protect cases where we did apply single when creating a checkpoint, but that code is no longer present.

      I don't see anywhere that we protect against multiple threads calling __wt_conn_btree_sync_and_close in parallel. Callers often hold the schema lock, but not always.

      I think the __wt_conn_btree_sync_and_close should re-check whether the handle is open after getting the close_lock and return if someone beat us to closing it.

            Assignee:
            david.hows David Hows
            Reporter:
            alexander.gorrod@mongodb.com Alexander Gorrod
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: