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.optionsorpymongo.mongo_client.MongoClient.optionsinstead.- Parameters:
- property auto_encryption_opts: AutoEncryptionOpts | None¶
A
AutoEncryptionOptsor None.
- property codec_options: CodecOptions[Any]¶
A
CodecOptionsinstance.
- property enable_overload_retargeting: bool¶
The configured enableOverloadRetargeting option.
Added in version 4.17.
- property event_listeners: list[_EventListeners]¶
The event listeners registered for this client.
See
monitoringfor details.Added in version 4.0.
- property load_balanced: bool | None¶
True if the client was configured to connect to a load balancer.
- property max_adaptive_retries: int¶
The configured maxAdaptiveRetries option.
Added in version 4.17.
- property pool_options: PoolOptions¶
A
PoolOptionsinstance.
- property read_concern: ReadConcern¶
A
ReadConcerninstance.
- 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
WriteConcerninstance.