Currently the RunCommand::runJobs terminates when it receives a SIGTERM or the $maxRuntime is expired. When this happens the running jobs are also terminated and remain as running.
This change makes sure that runJobs waits until all running jobs are finished and doesn't start any new jobs when it is instructed to shutdown.
Currently the
RunCommand::runJobs
terminates when it receives aSIGTERM
or the$maxRuntime
is expired. When this happens the running jobs are also terminated and remain asrunning
.This change makes sure that
runJobs
waits until all running jobs are finished and doesn't start any new jobs when it is instructed to shutdown.