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

Collection creation must be disallowed for collections undergoing a rename

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 6.1.0-rc0
    • Affects Version/s: 5.0.10, 5.3.3, 6.0.0-rc11, 6.1.0-rc0
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • Sharding EMEA 2022-06-27, Sharding EMEA 2022-07-11

      The RenameCollectionCoordinator does the following:

      1. Disallow all other DDL operations (excluding create) for the same db
      2. Check that the options are valid (e.g. make sure that the target collection does not exist if dropTarget = true).
        1. If checks are passing, the coordinator is not flagged as "complete on error".
      3. Rename participant commandss are invoked on each shard, the critical section is acquired for both collections.

      This flow is faulty because if an explicit/implicit create sneaks in between bullets 2 and 3, this causes the rename participant that is executing on the shard primary to hang indefinitely.

            Assignee:
            silvia.surroca@mongodb.com Silvia Surroca
            Reporter:
            pierlauro.sciarelli@mongodb.com Pierlauro Sciarelli
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: