A string describing the read preference mode (primary|primaryPreferred|secondary|secondaryPreferred|nearest)
Optionaltags: TagSet[]A tag set used to target reads to members with the specified tag(s). tagSet is not available if using read preference mode primary.
Optionaloptions: ReadPreferenceOptionsAdditional read preference options
OptionalhedgeOptionalmaxOptionalminOptionaltagsStaticnearestStaticNEARESTStaticprimaryStaticPRIMARYStaticPRIMARY_StaticprimaryStaticsecondaryStaticSECONDARYStaticSECONDARY_StaticsecondaryCheck if the two ReadPreferences are equivalent
The read preference with which to check equality
StaticfromConstruct a ReadPreference given an options object.
Optionaloptions: ReadPreferenceFromOptionsThe options object from which to extract the read preference.
StaticfromStaticisStatictranslateReplaces options.readPreference with a ReadPreference instance
The ReadPreference class is a class that represents a MongoDB ReadPreference and is used to construct connections.
See
https://www.mongodb.com/docs/manual/core/read-preference/