Atelierex / ProductsAPI

0 stars 0 forks source link

Look into using NGINX #3

Open eric-do opened 3 years ago

eric-do commented 3 years ago

https://github.com/May-Take-A-Second/ProductsAPI/blob/73d82e06da380a9c0f4ab61be48150b5b141a364/loadBalancer/loadBalancer.js#L7

I love that you wrote your own load balancer! Look into technologies that will help do this for you, such as NGINX. Ideally you put the LB on its own server, and have it point to your deployed services. The benefit being that you'd use mature and popular software, and be able to customize your load balancing strategies to see which works best for you under load.

pgoggles commented 3 years ago

Hey Eric, great suggestion, I actually switched to Nginx like an hour after using this loadBalancer, the loadBalancer I wrote was not very efficient. Nginx was way better, thank you! I'll remove this rudimentary implementation from my repository!