C- The type of connection.
public interface LoadBalancer<C extends LoadBalancedConnection> extends ListenableAsyncCloseable
SocketAddresses select the most desired
SocketAddressto use. This is typically used to determine which connection to issue a request to.
|Modifier and Type||Method and Description|
Select the most appropriate connection for a request.
Functionthat evaluates a connection for selection. This selector should return
nullif the connection MUST not be selected. This selector is guaranteed to be called for any connection that is returned from this method.
Singlethat completes with the most appropriate connection to use.