[SERVER-32847] Make copyDb transfer over UUIDs when it is called in metadataOnly mode Created: 23/Jan/18  Updated: 30/Oct/23  Resolved: 22/Mar/18

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 3.7.4

Type: Task Priority: Major - P3
Reporter: Kaitlin Mahar Assignee: Janna Golden
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by SERVER-4232 `show collections` on mongos doesn't ... Closed
Backwards Compatibility: Fully Compatible
Sprint: Sharding 2018-03-12, Sharding 2018-03-26
Participants:

 Description   

SERVER-32643 adds a metadataOnly mode to Cloner::copyDb, to be used when clone is called by configsvrMovePrimary.

Currently, copyDb uses Cloner::filterOptionsForClone to select out the info to copy over to the new instance of the DB. At that point it drops the UUIDs, but when we are using clone for movePrimary, we want to keep the UUIDs consistent since it is all one collection.

We should change filterOptionsForClone so that when metadataOnly=true, we either
a) verify the UUIDs match if the collection already exists on the new primary, or
b) use the collection's UUID from the old primary when we create it for the first time on the new primary.



 Comments   
Comment by Githook User [ 22/Mar/18 ]

Author:

{'email': 'golden.janna@gmail.com', 'name': 'jannaerin', 'username': 'jannaerin'}

Message: SERVER-32847: Make copyDb transfer UUIDs when creating collections
Branch: master
https://github.com/mongodb/mongo/commit/ff5abfee3587ade3501c4fdc2594bc53b492c08e

Generated at Thu Feb 08 04:31:28 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.