[SERVER-62556] Make rename across databases emit insert change events for temporary collection Created: 12/Jan/22  Updated: 29/Oct/23  Resolved: 03/Mar/22

Status: Closed
Project: Core Server
Component/s: Change streams
Affects Version/s: None
Fix Version/s: 6.0.0-rc0

Type: Improvement Priority: Major - P3
Reporter: Max Hirschhorn Assignee: Arun Banala
Resolution: Fixed Votes: 0
Labels: pm1950-m2
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Problem/Incident
Related
related to SERVER-62594 Allow cross-database renames to repor... Backlog
Backwards Compatibility: Fully Compatible
Sprint: QE 2022-03-07
Participants:
Linked BF Score: 180

 Description   

Renaming a collection across a database is similar to $out in that it creates a new temporary collection, creates matching indexes on the temporary collection, inserts documents into the temporary collection, and renames the temporary collection over the source. However, unlike $out, renaming across a database marks the insert oplog entries with {fromMigrate: true}. This prevents insert change events from being emitted for the temporary collection. We should stop setting {fromMigrate: true} to bring the $out and renameCollection behaviors into alignment.



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

Author:

{'name': 'Arun Banala', 'email': 'arun.banala@mongodb.com', 'username': 'banarun'}

Message: SERVER-62556 Fix typo
Branch: master
https://github.com/mongodb/mongo/commit/617c9326ebce121d64faee9c771bc9b68188aa7c

Comment by Githook User [ 02/Mar/22 ]

Author:

{'name': 'Arun Banala', 'email': 'arun.banala@mongodb.com', 'username': 'banarun'}

Message: SERVER-62556 Make rename across databases emit insert change events for temporary collection
Branch: master
https://github.com/mongodb/mongo/commit/ae0c9cf8327d54470175ac8a450df8f08e77578a

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