-
-
Notifications
You must be signed in to change notification settings - Fork 250
Labels
Description
Would be nice to have an exponential backoff feature when a process fails and you would like to restart it, but then allow that exponential backoff to be reset when the process is "alive" for a certain amount of time. As a start, this could even be simply allowing restartDelay option to take a function instead of a number.
Example:
- process fails -> immediate restart
- process fails -> restart after 2 seconds
- process fails -> restart after 4 seconds
- process fails -> restart after 8 seconds
- process "succeeds", where "success" is defined as "did not exit for 60 seconds after starting"
- process fails -> immediate restart
- process fails -> restart after 2 seconds
gustavohenke