Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-3475

Determine wire version and size limits from socket's ismaster, not server description

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: auth, libmongoc, network
    • None

      Per https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#warning-about-the-maxwireversion-from-a-monitor-s-ismaster-response drivers should determine the supported wire version, maxBsonObjectSize, maxMessageSizeBytes, and maxWriteBatchSize from the initial handshake on a socket.

      libmongoc does store these fields on a cluster node, but does not appear to use them when constructing the commands (even for the initial auth handshake). Instead, it uses the most recent server description from the topology, which may result in a race as described in the section of SDAM above.

            Assignee:
            Unassigned Unassigned
            Reporter:
            kevin.albertson@mongodb.com Kevin Albertson
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: