org.apache.ignite.internal.client.balancer

## Interface GridClientLoadBalancer

All Known Implementing Classes:
  GridClientBalancerAdapter, GridClientRandomBalancer, GridClientRoundRobinBalancer

    public interface GridClientLoadBalancer

Interface that defines a selection logic of a server node for a particular operation. Use it to define custom load balancing logic for client. Load balancer is specified via `GridClientConfiguration.getBalancer()` configuration property.

The following implementations are provided out of the box:

- `GridClientRandomBalancer`
- `GridClientRoundRobinBalancer`

### Method Summary

All Methods Instance Methods Abstract Methods
`GridClientNode` `balancedNode(Collection<? extends GridClientNode> nodes)` Gets next node for executing client command.

### Method Detail

#### balancedNode

    GridClientNode balancedNode(Collection<? extends GridClientNode> nodes)
                         throws GridClientException

Gets next node for executing client command.

Parameters:
  `nodes` - Nodes to pick from, should not be empty.
Returns:
  Next node to pick.
Throws:
  `GridClientException` - If balancer can't match given nodes with current topology snapshot.

${current.year} Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.12.0
Release Date | : January 10 2022