Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-6418

Change streams resume infinitely after failing to initialize cursor on server

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 6.10.0
    • Affects Version/s: None
    • Component/s: None
    • 0
    • Not Needed
    • Not Needed
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?

      Use Case

      As a... driver user
      I want... change streams to error when they fail to establish the change stream on the server
      So that... it doesn't attempt to resume indefinitely

      User Experience

      • Change streams will no longer infinitely retry following failure to setup on the server
      • not known, no reports at the moment

      Dependencies

      • Needed to finish implementing CSOT for change streams

      Risks/Unknowns

      • None

      Acceptance Criteria

      Implementation Requirements

      • Update _processErrorStreamMode to throw errors if change stream cursor has not been initialized
      • Update _processErrorIteratorMode to throw error if change stream cursor has not been initialized

      Testing Requirements

      • Add integration tests to ensure that ChangeStream.hasNext, ChangeStream.next, ChangeStream.tryNext throw and close the change stream when aggregate to establish server-side change stream fails
      • Add integration tests to ensure that when cursor is in emitter mode and aggregate to establish server-side change stream fails, the change stream emits an error event and closes the change stream

      Documentation Requirements

      • Should just be release notes

      Follow Up Requirements

      • Rebase CSOT PRs onto change when it merges

            Assignee:
            warren.james@mongodb.com Warren James
            Reporter:
            warren.james@mongodb.com Warren James
            Neal Beeken
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: