RpcLoadBalancer.LoadBalancer.SelectionAlgorithm.PowerOfTwo
(rpc_load_balancer v0.2.1)
Copy Markdown
View Source
Power of Two Choices node selection algorithm.
Picks two random nodes and selects the one with fewer active connections. Provides a good balance between simplicity and load distribution without the overhead of scanning all nodes like Least Connections.
Uses the same connection counter infrastructure as LeastConnections.
release_node/2 must be called when calls complete.