nss.rename(newNss, dropTarget) should only emit a single oplog event through the primary shard for the renamed and dropped namespaces

XMLWordPrintableJSON

    • Type: New Feature
    • Resolution: Fixed
    • Priority: Major - P3
    • 7.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Sharding EMEA
    • Fully Compatible
    • Sharding EMEA 2023-03-20
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      When a nss.rename(otherNss, dropTarget) command gets executed on a sharded target collection, every shard participating in the DDL is currently adding an internal {op: drop} event to its oplog when the target collection gets locally dropped.

      This may generate some ambiguity from the perspective of a mongos serving a otherNss.watch() request (which is collecting oplog events from multiple shards) to establish the exact point in time at which the change stream may be considered as invalidated.

      To solve this, non-primary shards participating in the rename collection DDL should mark their oplog events with the fromMigrate attribute.

              Assignee:
              Paolo Polato
              Reporter:
              Paolo Polato
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: