[SERVER-69603] Do not report drop events as part of shardCollection Created: 12/Sep/22  Updated: 29/Oct/23  Resolved: 28/Oct/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 6.1.1, 6.0.4, 6.2.0-rc0

Type: Bug Priority: Major - P3
Reporter: Lingzhi Deng Assignee: Enrico Golfieri
Resolution: Fixed Votes: 0
Labels: sharding-wfbf-day
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Problem/Incident
causes SERVER-71880 _shardsvrDropCollectionParticipant wi... Closed
causes SERVER-72235 Avoid the usage of dropCollectionEven... Closed
Backwards Compatibility: Fully Compatible
Backport Requested:
v6.1, v6.0
Sprint: Sharding EMEA 2022-10-03, Sharding EMEA 2022-10-17, Sharding EMEA 2022-10-31
Participants:

 Description   

The shardCollection command may drop the collection if there's a stepDown while it is running. Currently, this results in a drop collection event in change stream even though the collection isn't dropped from the user's perspective. I think if this drop is marked as fromMigrate: true, then it will skipped by change stream. And I think this is a more correct behavior.

With this spurious drop, it is very difficult/confusing for downstream to use change streams.



 Comments   
Comment by Githook User [ 09/Nov/22 ]

Author:

{'name': 'Enrico Golfieri', 'email': 'enrico.golfieri@mongodb.com', 'username': 'enricogolfieri'}

Message: SERVER-69603 Do not report drop events as part of shardCollection

(cherry picked from commit 22afc187e2a5ed450cf608458393830eb40b913a)
Branch: v6.0
https://github.com/mongodb/mongo/commit/2f3136c12e72cf707e409e6c3df4ef78b285b607

Comment by Githook User [ 09/Nov/22 ]

Author:

{'name': 'Enrico Golfieri', 'email': 'enrico.golfieri@mongodb.com', 'username': 'enricogolfieri'}

Message: SERVER-69603 Do not report drop events as part of shardCollection

(cherry picked from commit 22afc187e2a5ed450cf608458393830eb40b913a)
Branch: v6.1
https://github.com/mongodb/mongo/commit/7c0dec929a7ed5d98c7cec4983baee9a5eb4a998

Comment by Githook User [ 28/Oct/22 ]

Author:

{'name': 'Enrico Golfieri', 'email': 'enrico.golfieri@mongodb.com', 'username': 'enricogolfieri'}

Message: SERVER-69603 Do not report drop events as part of shardCollection
Branch: master
https://github.com/mongodb/mongo/commit/22afc187e2a5ed450cf608458393830eb40b913a

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