My application boot time is slow and leaves the app unavailable during dyno restarts.
For zero-downtime deploys and restarts, we recommend using Preboot for Common Runtime apps. Some apps aren't compatible with Preboot, so please be sure to check the documentation carefully.
Ensure that your
web process only runs the necessary commands to start a web server. For example, any asset compilation or build steps (e.g.
webpack for Node apps) should be moved to the build phase. For Node JS applications specifically, we have some guidance on this here: https://devcenter.heroku.com/articles/node-best-practices#hook-things-up.