client_options
– Read only configuration options for a MongoClient.¶
Tools to parse mongo client options.
See also
This module is compatible with both the synchronous and asynchronous PyMongo APIs.
- class pymongo.client_options.ClientOptions¶
Read only configuration options for an AsyncMongoClient/MongoClient.
Should not be instantiated directly by application developers. Access a client’s options via
pymongo.mongo_client.AsyncMongoClient.options
orpymongo.mongo_client.MongoClient.options
instead.- Parameters:
- property auto_encryption_opts: AutoEncryptionOpts | None¶
A
AutoEncryptionOpts
or None.
- property codec_options: CodecOptions¶
A
CodecOptions
instance.
- property event_listeners: list[_EventListeners]¶
The event listeners registered for this client.
See
monitoring
for details.Added in version 4.0.
- property load_balanced: bool | None¶
True if the client was configured to connect to a load balancer.
- property pool_options: PoolOptions¶
A
PoolOptions
instance.
- property read_concern: ReadConcern¶
A
ReadConcern
instance.
- property read_preference: _ServerMode¶
A read preference instance.
- property server_monitoring_mode: str¶
The configured serverMonitoringMode option.
Added in version 4.5.
- property timeout: float | None¶
The configured timeoutMS converted to seconds, or None.
Added in version 4.2.
- property write_concern: WriteConcern¶
A
WriteConcern
instance.