You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using Gunicorn on Heroku in Docker container along with Nginx/Supervisor.
When Heroku scales down it first sends SIGTERM to all processes in the container and after 30 seconds it sends SIGKILL. I don't think, that I can change this behavior.
The correct behavior should be, that Nginx start terminate process first and stops accepting new requests and then Gunicorn starts it's termination. Otherwise the Heroku router sends new request to the terminating session (more described here: https://www.schneems.com/2019/07/12/puma-4-hammering-out-h13sa-debugging-story/).
The problem is that Heroku sends SIGTERM to all processes in the instance and the order of their termination is random.
I wonder if there could be added some possibility to wait defined number of seconds before the terminate process starts.
The text was updated successfully, but these errors were encountered:
I am using Gunicorn on Heroku in Docker container along with Nginx/Supervisor.
When Heroku scales down it first sends SIGTERM to all processes in the container and after 30 seconds it sends SIGKILL. I don't think, that I can change this behavior.
The correct behavior should be, that Nginx start terminate process first and stops accepting new requests and then Gunicorn starts it's termination. Otherwise the Heroku router sends new request to the terminating session (more described here: https://www.schneems.com/2019/07/12/puma-4-hammering-out-h13sa-debugging-story/).
The problem is that Heroku sends SIGTERM to all processes in the instance and the order of their termination is random.
I wonder if there could be added some possibility to wait defined number of seconds before the terminate process starts.
The text was updated successfully, but these errors were encountered: