Uploaded image for project: 'Go Driver'
  1. Go Driver
  2. GODRIVER-1535

endSessions batching must reset BSON array index

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.3.2
    • Component/s: None
    • Labels:
      None

      Description

      When we batch sessions for the endSessions command, the BSON array we generate after the first batch does not have indexes starting from 0. This causes a server error. Per the spec, we ignore errors for endSessions and I don't think we have tests that cause more than 10000 sessions to be pooled so this is missing test coverage.

       

      Writing a test in mongo/integration would be expensive because we'd need to create 10k sessions, but we can write a test in mongo to manually reduce the batch size and use command monitoring to make assertions.

        Attachments

          Activity

            People

            Assignee:
            divjot.arora Divjot Arora
            Reporter:
            divjot.arora Divjot Arora
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: