-
Type: Bug
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Execution
-
ALL
Change streams use a number of internal events, such as migrateLastChunkFromShard and migrateChunkToNewShard, to detect cluster-level topology changes. These are bubbled up to mongoS and consumed by an internal stage; the events are not surfaced to the client.
However, it is conceivable that under certain circumstances, the resume token of that internal event may become the PBRT of the next batch returned to the client. If the user attempts to resume from that token, the DSCSHandleToplogyChange stage would again swallow the event before DSCSEnsureResumeTokenPresent has a chance to see it, causing the latter stage to believe that the event did not appear in the resumed stream and resulting in ChangeStreamFatalError being thrown to the client.