Table of Contents

Method GetReadChannelSource

Namespace
MongoDB.Driver.Core.Bindings
Assembly
MongoDB.Driver.Core.dll

GetReadChannelSource(CancellationToken)

Gets a channel source for read operations.

public IChannelSourceHandle GetReadChannelSource(CancellationToken cancellationToken)

Parameters

cancellationToken CancellationToken

The cancellation token.

Returns

IChannelSourceHandle

A channel source.

GetReadChannelSource(IReadOnlyCollection<ServerDescription>, CancellationToken)

Gets a channel source for read operations while deprioritizing servers in the provided collection.

public IChannelSourceHandle GetReadChannelSource(IReadOnlyCollection<ServerDescription> deprioritizedServers, CancellationToken cancellationToken)

Parameters

deprioritizedServers IReadOnlyCollection<ServerDescription>

The deprioritized servers.

cancellationToken CancellationToken

The cancellation token.

Returns

IChannelSourceHandle

A channel source.