FireDAC.Phys.MongoDBWrapper.TMongoReadPreference.TReadMode

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

TReadMode = (Primary, Secondary, PrimaryPreferred, SecondaryPreferred, Nearest);

C++

enum class DECLSPEC_DENUM TReadMode : unsigned int { Primary, Secondary, PrimaryPreferred, SecondaryPreferred, Nearest };

Properties

Type Visibility Source Unit Parent
enum public
FireDAC.Phys.MongoDBWrapper.pas
FireDAC.Phys.MongoDBWrapper.hpp
FireDAC.Phys.MongoDBWrapper TMongoReadPreference

Description

Defines an enumeration used to specify the read preference modes.

The values of TReadMode specify the read preference modes.

This enumeration defines the following values:

  • Primary: Default mode. All operations read from the current replica set primary.
  • PrimaryPreferred: In this mode, operations read from the primary. If it is unavailable, operations read from the secondary members of the replica set.
  • Secondary: In this mode, all operations read from the secondary members of the replica set.
  • SecondaryPreferred: In this mode, operations read from the secondary members but if no secondary members are available, operations read from the primary.
  • Nearest: In this mode, operations read from a member of the replica set with the least network latency, irrespective of the members type.

See Also