MongoClientSettings.authMechanism

Use the given authentication mechanism when connecting to the server. If unsupported by the server, throw a MongoAuthException.

If set to none, but digest or sslPEMKeyFile are set, this automatically determines a suitable authentication mechanism based on server version.

class MongoClientSettings
MongoAuthMechanism authMechanism;

Meta