fedn.network.loadbalancer package

The loadbalancer package is responsible for loadbalancing the clients to the combiners.

Submodules

fedn.network.loadbalancer.firstavailable module

class fedn.network.loadbalancer.firstavailable.LeastPacked(network)[source]

Bases: LoadBalancerBase

Load balancer that selects the first available combiner.

Parameters:

network (class: fedn.network.api.network.Network) – A handle to the network.

find_combiner()[source]

Find the first available combiner.

fedn.network.loadbalancer.leastpacked module

class fedn.network.loadbalancer.leastpacked.LeastPacked(network)[source]

Bases: LoadBalancerBase

Load balancer that selects the combiner with the least number of attached training clients.

Parameters:

network (class: fedn.network.api.network.Network) – A handle to the network.

find_combiner()[source]

Find the combiner with the least number of attached clients.

fedn.network.loadbalancer.loadbalancerbase module

class fedn.network.loadbalancer.loadbalancerbase.LoadBalancerBase(network)[source]

Bases: ABC

Abstract base class for load balancers.

Parameters:

network (class: fedn.network.api.network.Network) – A handle to the network.

abstract find_combiner()[source]

Find a combiner to connect to.