ksysoev / wasabi

Toolkit for Creating WebSocket API Gateways
MIT License
4 stars 2 forks source link

Add possibility to define weight for nodes in load balancer logic #91

Open ksysoev opened 1 week ago

ksysoev commented 1 week ago

In current implementation all backends are considered to be equal, and balanser will try to distribute load equally across all of them. In real production environment it could be possible that some nodes may have to have more resources than other. For such cases we should be able to provide possibility define node weight.

load should work as follows, if node weight is 2 it should be handling twice more request to compare to node with weight 1.

ksysoev commented 6 days ago

this probably better to define through policy, rather try to fit into current algorithm.