Demon.FE
Demon.FE

Reputation: 29

what's pm2 auto restart strategy?

what's pm2 auto restart strategy?

I tried to use pm2 to start the Next.js application, React rendering errors, Pm2 can see the Error log, but will not restart.

I tried to use Pm2 to start a simple Koa application. When processing the network request, I triggered a JS error and Pm2 can see the Error log, but Pm2 did not restart.

Upvotes: 0

Views: 796

Answers (1)

Shatish Desai
Shatish Desai

Reputation: 605

Restart app at a specified CRON time
Restart app when files have changed
Restart when app reach a memory threshold
Delay a start and automatic restart
Disable auto restart (app are always restarted with PM2) when crashing or exiting by default)
Restart application automatically at a specific exponential increasing time

Reference Link : https://pm2.keymetrics.io/docs/usage/restart-strategies/

i hope this link will help you

Upvotes: 2

Related Questions