2 Sample HA Proxy Configuration

This topic describes about the HA Proxy Configuration.

A load balancer such as HAProxy, NGINX, Oracle HTTP Server, etc. may be used for high-availability." in case there isn't an existing general reference to load balancers.

Sample basic configuration in HAProxy for API Gateway (set in etc/haproxy/haproxy.conf)

frontend LBGateway
    bind load.balancer.ip.address:port
    default_backend LBGateway
 
backend LBGateway load.balancer.ip.address:port
    mode http
    balance roundrobin
    option httpchk
    option http-keep-alive
    option forwardfor
    option httpchk HEAD /app-shell
    server <backend_server_name_1> api.gateway1.ip.address:api_gateway_port_1 check
    server <backend_server_name_1> api.gateway2.ip.address:api_gateway_port_2 check