[SERVER-57532] Use donor specs for _id index in tenant migration collection cloner Created: 08/Jun/21  Updated: 29/Oct/23  Resolved: 11/Jun/21

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 5.0.0-rc2, 5.1.0-rc0

Type: Bug Priority: Major - P3
Reporter: Xuerui Fa Assignee: Vishnu Kaushik
Resolution: Fixed Votes: 0
Labels: post-rc0
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v5.0
Sprint: Repl 2021-06-14
Participants:
Linked BF Score: 36

 Description   

In the tenant migration cloner, we separate the _id index from other index builds. We rely on the createCollection code path to build the _id index with default specs, whereas for other indexes, we will use the specs from the donor.

Because of this, if the user specifies v: 1 for their index builds, it seems possible for there to be a mismatch between the versions. Since there is a semantic difference between v:1 and v:2 indexes, we should use the user's specs when building the _id index.



 Comments   
Comment by Vivian Ge (Inactive) [ 06/Oct/21 ]

Updating the fixversion since branching activities occurred yesterday. This ticket will be in rc0 when it’s been triggered. For more active release information, please keep an eye on #server-release. Thank you!

Comment by Githook User [ 16/Jun/21 ]

Author:

{'name': 'Vishnu Kaushik', 'email': 'vishnu.kaushik@mongodb.com', 'username': 'kauboy26'}

Message: SERVER-57532 Use donor specs for _id index in tenant migration collection cloner
Branch: v5.0
https://github.com/mongodb/mongo/commit/2aca88acdf18714923961fdfd6c99915f56570a5

Comment by Githook User [ 10/Jun/21 ]

Author:

{'name': 'Vishnu Kaushik', 'email': 'vishnu.kaushik@mongodb.com', 'username': 'kauboy26'}

Message: SERVER-57532 Use donor specs for _id index in tenant migration collection cloner
Branch: master
https://github.com/mongodb/mongo/commit/0d7c224fc2671e939ea97d94237003dd74805b54

Comment by Lingzhi Deng [ 09/Jun/21 ]

I think one solution is to extend StorageInterfaceImpl::createCollection to take in a _id spec so it can pass down to DatabaseImpl::createCollection.

Generated at Thu Feb 08 05:42:06 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.