Uploaded image for project: 'Python Driver'
  1. Python Driver
  2. PYTHON-1759

Command failures on find/getMore do not reset the server's SDAM state

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Minor - P4 Minor - P4
    • 3.9
    • Affects Version/s: None
    • Component/s: Internal, Query Operations
    • Labels:
      None

      The SDAM spec says that certain command errors "detected from a getLastError response, write command response, or query response" must reset the server's SDAM state:
      https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-master-and-node-is-recovering

      PyMongo does this for write commands and getLastError but not for command errors for find/getMore. I've marked this as minor because these kinds of errors mean the server is in the process of shutting down or stepping down in which case the connections will be closed and a future heartbeat will update the SDAM state anyway.

            Assignee:
            shane.harvey@mongodb.com Shane Harvey
            Reporter:
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: