Improve my current API Server
Currently I use HAproxy as my API gateway
On my backend I have 3 servers for processing the requests, each server has a list of proxy IP addresses in a [login to view URL] file that I rotate 'round robin' for each request.
If the proxys fail currently I have to manually find the failed proxies and remove the failed proxies from the [login to view URL] list on each server.
I would like to setup a health checks on the proxies and if they fail they will be automatically removed from the servers.
It makes sense if possible to do this on the HAproxy server and forward the working proxy in a header for each request rather than each server mananage its own list.
Is this possible with HAProxy? or do we need to create a service before HAproxy to add the proxy header then forward to HAproxy?
Currently I use [login to view URL] and they provide an API to add/remove proxies.
I want to automatically remove proxies as they fail , and learn based on previous failed proxies which vlans to avoid.
If you are interested in this job , in breif please summerise what solution you promose.
Bonus would be able to cache requests as well
Code to be in node js