How to automatically retry Apache connection to application server if it returns 503? -


i have apache server set reverse proxy application server works fine generally.

however set if application server returns unavailable 503, apache waits 1-2 seconds , retries again.

note - retry parameter in documentation refers caching of 503 response , how long before checking app server (not in same request).

all can find called setretryhandler it's on head , i'm not sure how use (seems in apache source code perhaps).

does have suggestions please?

this isn't easy task, mod_proxy doing it's told (and designed do), deliver right message backend.

you can work around this, believe, using "holding page" on frontend redirects. achieve that, should set proxyerroroverride on, , have 503 errors redirected holding page errordocument 503 /some_holding_page, have page either html page refresh mechanism, or script sleeps 1-2 seconds , redirects page caused error.


Comments