Buffer requests in nginx while a symlink switches on backend
- by Quintin Par
In a release deployment I would like to buffer client requests that come to nginx(in reverse proxy) mode to be buffered for possibily 1-2 seconds while a pdsh request is sent to switch symlinks on the back end server to /var/www/html/current .
After the switch is complete, I would want to release the buffering while avoiding a herd clash.
Is this possible in nginx? Can someone help?
Edit:
The idea is not to loose requests and from nginx forums I've come to know that retries can sometimes results in CPU spins