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

Allow cross-database renames to report the original namespace and UUID

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Execution

      Cross-database collection renames currently work by writing all data from the original collection into a temp collection on the new database, renaming that collection to the target namespace, and then dropping the original collection. After PM-1950, change streams will report all these steps explicitly, allowing a client application to deduce what has happened.

      However, it might be preferable to instead hide the inserts into the temporary collection behind a fromMigrate flag, and give change streams a way to simply report the final rename from the original namespace to the new namespace. This would require some changes to the oplog format, possibly by recording the namespace and uuid of the original collection in the o2 field of the final renameCollection oplog entry.

            Assignee:
            backlog-query-execution [DO NOT USE] Backlog - Query Execution
            Reporter:
            bernard.gorman@mongodb.com Bernard Gorman
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: