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

Optimize find/aggregate/command by avoiding duplicate calls to _get_topology

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Unknown Unknown
    • 4.8, 4.7.3
    • Affects Version/s: None
    • Component/s: None
    • None
    • Python Drivers
    • Not Needed
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?

      Optimize find/aggregate/command by avoiding duplicate calls to _get_topology. The read and database.command() code paths accidentally call _get_topology() twice. _get_topology is expensive since it requires locks and checking the state of running threads.

      Related to PYTHON-4347.

            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: