New UseMongoDB overloads

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Done
    • Priority: Unknown
    • 9.0.1, 8.3.1
    • Affects Version/s: None
    • None
    • None
    • Dotnet Drivers
    • None
    • None
    • None
    • None
    • None
    • None

      Right now we support basically two UseMongoDB overloads:

      .UseMongoDB(connectionString, databaseName)
      .UseMongoDB(mongoClient, databaseName)

      We want to de-emphasize mongoClient as it:

      1. Makes ASP.NET DI setup more cumbersome
      2. Makes disposal ambiguous
      3. Can't be used by Queryable Encryption builder

      Instead we should add two new overloads:

      .UseMongoDB(connectionString)

      Takes a connection string without a separate database name to be more familiar with some other providers as well as Mongoose etc. and simpler DI setup.

      .UseMongoDB(mongoClientSettings, databaseName)

      As the alternative to the MongoClient overload for manual configuration through code.

              Assignee:
              Damien Guard
              Reporter:
              Damien Guard
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: