MCPcopy Create free account
hub / github.com/apache/cassandra-python-driver / get_max_connections_per_host

Method get_max_connections_per_host

cassandra/cluster.py:1599–1609  ·  view source on GitHub ↗

Gets the maximum number of connections per Session that will be opened for each host with :class:`~.HostDistance` equal to `host_distance`. The default is 8 for :attr:`~HostDistance.LOCAL` and 2 for :attr:`~HostDistance.REMOTE`. This property is ignored if :

(self, host_distance)

Source from the content-addressed store, hash-verified

1597 self._ensure_core_connections()
1598
1599 def get_max_connections_per_host(self, host_distance):
1600 """
1601 Gets the maximum number of connections per Session that will be opened
1602 for each host with :class:`~.HostDistance` equal to `host_distance`.
1603 The default is 8 for :attr:`~HostDistance.LOCAL` and 2 for
1604 :attr:`~HostDistance.REMOTE`.
1605
1606 This property is ignored if :attr:`~.Cluster.protocol_version` is
1607 3 or higher.
1608 """
1609 return self._max_connections_per_host[host_distance]
1610
1611 def set_max_connections_per_host(self, host_distance, max_connections):
1612 """

Callers 4

test_cluster_settingsMethod · 0.80
borrow_connectionMethod · 0.80

Calls

no outgoing calls

Tested by 1

test_cluster_settingsMethod · 0.64