[SERVER-76289] During shard split or merge, creating a new change stream after the block timestamp might skip events on the recipient Created: 19/Apr/23  Updated: 29/Oct/23  Resolved: 04/May/23

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 7.1.0-rc0

Type: Bug Priority: Major - P3
Reporter: Mickey Winters Assignee: Mickey Winters
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: QE 2023-05-15
Participants:

 Description   
  • Donor blocks writes  for tenant1 at TS(100).
  • New $changeStream aggregate comes in, initializes start time to current clusterTime, TS(300), returns empty batch with PBRT=TS(300)
  • Migration commits. We advance the recipient clock to be at least  blockTS , here is TS(100).
  • On Recipient, new writes starts to come in  and they writes at TS(200).
  • Client issues CS getMore, gets ResumeTenantChangeStream, driver retries
  • CS cursor resumes from the last token it saw, i.e. the PBRT at TS(300)
  • Change stream resumes on recipient but skips all events that occurred between TS(100) and TS(300)


 Comments   
Comment by Githook User [ 03/May/23 ]

Author:

{'name': 'Mickey. J Winters', 'email': 'mickey.winters@mongodb.com', 'username': 'mjrb'}

Message: SERVER-76289 Block opening new change streams during shard split or shard merge critical section
Branch: master
https://github.com/mongodb/mongo/commit/01e26506a0981b4141bc65c9d016666ada60319e

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