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

detect namespace changes when refreshing Collection after yielding

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.3.2, 6.0.0-rc0, 5.0.9
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • v5.3, v5.0
    • Execution Team 2022-04-04, Execution Team 2022-04-18
    • 136

      The LookupCollectionForYieldRestore functor, defined in collection_catalog.cpp, is responsible for looking up the collection in the catalog in order to restore the internal state of the CollectionPtr.

      The functor returns a nullptr in the case of drops but still returns a non-null pointer if there was a rename while yielding. For renames, the resulting CollectionPtr state might be inconsistent with the resource IDs in the restored lock state. Additionally, since changes to the catalog results in new COW-induced versions of the catalog, there is a risk of a stale catalog.

            Assignee:
            benety.goh@mongodb.com Benety Goh
            Reporter:
            benety.goh@mongodb.com Benety Goh
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: