Uploaded image for project: 'Drivers'
  1. Drivers
  2. DRIVERS-233

Do not validate the "startingFrom" field in OP_REPLY.

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Component/s: None
    • Labels:
    • $i18n.getText("admin.common.words.hide")
      Key Status/Resolution FixVersion
      PYTHON-945 Done 3.0.3, 2.9
      RUST-18 Done
      SWIFT-465 Done
      $i18n.getText("admin.common.words.show")
      #scriptField, #scriptField *{ border: 1px solid black; } #scriptField{ border-collapse: collapse; } #scriptField td { text-align: center; /* Center-align text in table cells */ } #scriptField td.key { text-align: left; /* Left-align text in the Key column */ } #scriptField a { text-decoration: none; /* Remove underlines from links */ border: none; /* Remove border from links */ } /* Add green background color to cells with FixVersion */ #scriptField td.hasFixVersion { background-color: #00FF00; /* Green color code */ } /* Center-align the first row headers */ #scriptField th { text-align: center; } Key Status/Resolution FixVersion PYTHON-945 Done 3.0.3, 2.9 RUST-18 Done SWIFT-465 Done

      OP_REPLY in the MongoDB wire protocol includes a "startingFrom" field. It is defined as a signed 32 bit integer. That's unfortunate since a MongoDB collection can have a much larger number of documents. If you validate this field (like the python driver...) a user that iterates a large collection (more than 2147483647 documents) will receive an error when the server overflows the startingFrom value and returns a negative number.

      The consensus of opinion seems to be that validating this field isn't particularly useful. If your driver does validate, remove the validation.

      http://docs.mongodb.org/meta-driver/latest/legacy/mongodb-wire-protocol/#op-reply

            Assignee:
            barrie Barrie Segal
            Reporter:
            bernie@mongodb.com Bernie Hackett
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: