Table of Contents

Class ClusterSettings

Namespace
MongoDB.Driver.Core.Configuration
Assembly
MongoDB.Driver.dll

Represents settings for a cluster.

public class ClusterSettings
Inheritance
ClusterSettings
Inherited Members

Constructors

ClusterSettings(Optional<CryptClientSettings>, Optional<bool>, Optional<IEnumerable<EndPoint>>, Optional<bool>, Optional<TimeSpan>, Optional<int>, Optional<string>, Optional<ServerApi>, Optional<TimeSpan>, Optional<IServerSelector>, Optional<IServerSelector>, Optional<ConnectionStringScheme>, Optional<int>, Optional<string>)

Initializes a new instance of the ClusterSettings class.

Properties

CryptClientSettings

Gets the crypt client settings.

DirectConnection

Gets the DirectConnection.

EndPoints

Gets the end points.

LoadBalanced

Gets whether to use load balanced.

LocalThreshold

Gets the local threshold.

MaxServerSelectionWaitQueueSize

Gets the maximum size of the server selection wait queue.

PostServerSelector

Gets the post server selector.

PreServerSelector

Gets the pre server selector.

ReplicaSetName

Gets the name of the replica set.

Scheme

Gets the connection string scheme.

ServerApi

Gets the server API.

ServerSelectionTimeout

Gets the server selection timeout.

SrvMaxHosts

Limits the number of SRV records used to populate the seedlist during initial discovery, as well as the number of additional hosts that may be added during SRV polling.

SrvServiceName

Gets the SRV service name which modifies the srv URI to look like:

_{srvServiceName}._tcp.{hostname}.{domainname}

The default value is "mongodb".

Methods

With(Optional<CryptClientSettings>, Optional<bool>, Optional<IEnumerable<EndPoint>>, Optional<bool>, Optional<TimeSpan>, Optional<int>, Optional<string>, Optional<ServerApi>, Optional<TimeSpan>, Optional<IServerSelector>, Optional<IServerSelector>, Optional<ConnectionStringScheme>, Optional<int>, Optional<string>)

Returns a new ClusterSettings instance with some settings changed.