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

collection_names, options, and index_information prohibited on direct connection to secondary with MongoDB 3.0+

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.8.1
    • Affects Version/s: 2.8
    • Component/s: None
    • Labels:
      None
    • Fully Compatible

      MongoDB 3.0 introduced commands to retrieve metadata, in place of queries on system collections. SERVER-15994 then changed the new commands to require the slaveOk bit be set when run against a secondary/slave. PyMongo 2.8's MongoClient calls these commands with read preference PRIMARY, ignoring the read preference configured at collection, command, or client level, and doesn't set the slaveOk bit. This leaves PyMongo 2.x users with no way to query metadata over a direct connection to a MongoDB 3.0+ secondary or slave. PyMongo 3.x already does the right thing.

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

              Created:
              Updated:
              Resolved: