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

MasterSlaveConnection.in_request() and MongoReplicaSetClient.in_request() are wrong if multithreaded

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Minor - P4 Minor - P4
    • 2.4.2
    • Affects Version/s: 2.3
    • Component/s: None
    • None

      Repro:

      Create MasterSlaveConnection or MongoReplicaSetClient with auto_start_request=False. Thread A calls start_request(). Thread B calls in_request().

      Expected: in_request() is False for thread B

      Actual: in_request() is True for thread B, but thread B is not actually in a request (it doesn't have a reserved socket on master / primary)

            Assignee:
            jesse@mongodb.com A. Jesse Jiryu Davis
            Reporter:
            jesse@mongodb.com A. Jesse Jiryu Davis
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: