Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the minUptime

I am using forever with my project. What do these options do:

  • minUptime
  • spinSleepTime

I didn't understand from GitHub page.

like image 951
Tolgay Toklar Avatar asked Aug 22 '13 21:08

Tolgay Toklar


1 Answers

Forever's documentation explains each briefly:

--minUptime      Minimum uptime (millis) for a script to not be considered "spinning"
--spinSleepTime  Time to wait (millis) between launches of a spinning script.

A "spinning" application is one that keeps failing/crashing shortly after a restart.

--minUptime sets the minimum amount of time that an application is expected to run. If it crashes before that limit, it's considered to be "spinning" or problematic.

--spinSleepTime sets an amount of time that forever will wait before trying to restart a "spinning" application again.

Collectively, they help prevent having an application rapidly being restarted only to crash each time.

like image 193
Jonathan Lonowski Avatar answered Oct 31 '22 21:10

Jonathan Lonowski