cl-yxorp
cl-yxorp copied to clipboard
Loadbalancer
Hey, looks like cool stuff! Think for production use load balancing would be a big plus / must have. Thanks a lot if possible to make that happen!
If you have some load balancing code you can plug it into your own :destinator. I have considered including such load balancing algorithms for use, but ther are many types and it seems most are non-trivial. Is there a specific load balancing algorithm you are interested in having?
Thanks for the hint with : destinator
No don't have the code. I just discovered your package and am surprised there exists a cl replacement for nginx at all which is great! I need to try your implementation!
Regarding the load balancing there are round robin, least connection and hash approaches (IP or generic), c.f. https://dzone.com/articles/nginx-reverse-proxy-and-load-balancing
Don't know exactly which one is favourable and I need to research or ask someone else.
Round robin shouldn't be too hard to do. Maybe you could play around with something like a make-round-robin
function that take a variable number of port and host names and returns a destinator function that will do the round robin work. I would be happy to take a look at a pull request.