Writing a weighted load balancing algorithm
问题 I've to write a weighted load balancing algorithm and I'm looking for some references. Is there any book ? that you can suggest to understand such algorithms. Thanks! 回答1: A simple algorithm here isn't that complicated. Let's say you have a list of servers with the following weights: A 10 B 20 C 30 Where the higher weight represents it can handle more traffic. Just divide the amount of traffic sent to each server by the weight and sort smallest to largest. The server that comes out on top