Server can return stale topologyVersion to clients on stepdown due to heartbeats

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 7.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Replication
    • Fully Compatible
    • ALL
    • Repl 2023-07-24
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Currently, I think it's possible that the server will kill operations as part of stepdown due to heartbeats , and return a stale TopologyVersion because we don't call fulfillTopologyPromise (as part of _updateMemberStateFromTopologyCoordinator) until after we kill the operations.

      This causes issues with retryable writes if a server returns a response with error InterruptedDueToReplStatechange with topologyVersion N (unchanged), and the driver will not know to mark the server as unknown before retrying the same write to the same node that is no longer a primary.

              Assignee:
              Matthew Russotto
              Reporter:
              Jason Chan
              Votes:
              0 Vote for this issue
              Watchers:
              11 Start watching this issue

                Created:
                Updated:
                Resolved: