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

listCollections can return empty metadata for a collection which has been concurrently dropped

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.0.0-rc0, 5.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
    • Fully Compatible
    • ALL
    • v5.0
    • Execution Team 2021-05-17, Execution Team 2021-05-31
    • 158

      This is very similar to SERVER-56002, whereby a lock-free operation attempts to access the DurableCatalog while a concurrent operation is modifying it. For listCollections, its possible to lookup the collection in the CollectionCatalog just before a collection has been dropped, which means it no longer has an entry in the DurableCatalog. Then, when listCollections proceeds to read the collection options, it receives an empty object and returns it in the command response.

      One possible downstream impact for this is a failed shardCollection command when try to extract the UUID of the collection to shard.

            henrik.edin@mongodb.com Henrik Edin
            nicholas.zolnierz@mongodb.com Nicholas Zolnierz
            0 Vote for this issue
            8 Start watching this issue