Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-5474

Incorrect execution of killCursors after failed getMore in LOAD_BALANCED mode

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Unknown Unknown
    • 5.2.0
    • Affects Version/s: None
    • Component/s: CSOT
    • None
    • Java Drivers
    • 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?

      Description: When a getMore operation fails with CSOT being enabled, and the associated pinned connection is subsequently closed, any following killCursor operations on that connection fail with an error stating "cannot write to a closed stream".

      According to the specification for serverless topologies operating in LOAD_BALANCED mode, this behavior is incorrect. The spec dictates that if a getMore fails due to a network error, the connection should remain pinned to the cursor, and killCursors should not be executed when the cursor’s close method is invoked.

      Expected Behavior: The connection remains pinned to the cursor after a getMore network failure, and no killCursors command is executed upon invoking the cursor’s close method.

      Actual Behavior: The killCursors command is executed when the cursor's close method is invoked after a getMore network failure, which contradicts the specifications for LOAD_BALANCED mode in a serverless topology.

            Assignee:
            slav.babanin@mongodb.com Slav Babanin
            Reporter:
            slav.babanin@mongodb.com Slav Babanin
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: