According to "Are the dyno restarts on Heroku simultaneous?", Heroku restarts dynos randomly throughout the day, and only gives 10 seconds after SIGTERM for the processes to finish up.
We have long-running processes running on Heroku. Is it possible to force Heroku to prevent each dyno from receiving new requests longer than 10 seconds (e.g. 10 minutes) before restarting that dyno?
Is it possible to force Heroku to prevent each dyno from receiving new requests longer than 10 seconds
No.
The Dyno Manager restarts your dyno(s) when:
See here:
Regarding the answer in the post you shared:
Heroku restarts dynos randomly -- sometimes multiple times per day. Don't count on it being simultaneous!
That's a bit misleading; Heroku restarts your dynos approximately once every 24 hours. It is per dyno, not per app, and so they should not coincide. If a dyno crashes, it can be restarted, and the 24 hour period is reset (basically; it's a new dyno, new cycle).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With