Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-2263

Testing framework should auto-detect if being run against a replica set

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor - P4 Minor - P4
    • 2.7.0
    • None
    • Testing
    • None

    Description

      The testing framework uses a default connection string of

      mongodb://localhost 

      Which does not work when run against a replica set, at least not when 27017 is not the primary.

      If no connection string is provided to the testing framework (via an environment variable), the testing framework should probe the server at 27017 and use the following connection string instead if the server at 27017 is a member of a replica set:

      mongodb://localhost/?connect=replicaSet 

       

       

       

      Attachments

        Activity

          People

            robert@mongodb.com Robert Stam
            robert@mongodb.com Robert Stam
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: