Commit Graph

1 Commits

Author SHA1 Message Date
Shane Harvey
e95d2187b6
PYTHON-2395 Consider connection pool health during server selection (#515)
Change the driver to maintain a count of in-progress operations to each
server (per client). When selecting a mongos server, the driver now picks
2 suitable servers at random and selects the server with fewer in-progress
operations. Previously, the driver selected a mongos server at random.
The new behavior is intended to route operations away from unhealthy or
slow servers in highly concurrent single client workloads.

PYTHON-2460 Only reset Pool.active_sockets to 0 after a fork()
2020-12-07 10:41:39 -10:00