MCPcopy Index your code
hub / github.com/mongodb/mongo-python-driver / _connect

Method _connect

pymongo/synchronous/mongo_client.py:1033–1035  ·  view source on GitHub ↗

Explicitly connect to MongoDB synchronously instead of on the first operation.

(self)

Source from the content-addressed store, hash-verified

1031 return opts
1032
1033 def _connect(self) -> None:
1034 """Explicitly connect to MongoDB synchronously instead of on the first operation."""
1035 self._get_topology()
1036
1037 def _init_background(self, old_pid: Optional[int] = None) -> None:
1038 self._topology = Topology(self._topology_settings)

Calls 1

_get_topologyMethod · 0.95