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

Method update_is_writable

pymongo/synchronous/pool.py:898–905  ·  view source on GitHub ↗

Updates the is_writable attribute on all sockets currently in the Pool.

(self, is_writable: Optional[bool])

Source from the content-addressed store, hash-verified

896 conn.close_conn(ConnectionClosedReason.STALE)
897
898 def update_is_writable(self, is_writable: Optional[bool]) -> None:
899 """Updates the is_writable attribute on all sockets currently in the
900 Pool.
901 """
902 self.is_writable = is_writable
903 with self.lock:
904 for _socket in self.conns:
905 _socket.update_is_writable(self.is_writable) # type: ignore[arg-type]
906
907 def reset(
908 self, service_id: Optional[ObjectId] = None, interrupt_connections: bool = False

Callers 2

_update_serversMethod · 0.45
checkinMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected