public interface JobProcessManager
| Modifier and Type | Method and Description |
|---|---|
void |
kill(KillService.KillSource source)
Terminate job process execution (if still running) or prevent it from launching (if not launched yet).
|
void |
launchProcess(java.io.File jobDirectory,
java.io.File jobScript,
boolean interactive,
java.lang.Integer timeout,
boolean launchInJobDirectory)
Launch the job process (unless launch was aborted by previous a
kill call). |
JobProcessResult |
waitFor()
Wait indefinitely for the job process to terminate.
|
void launchProcess(java.io.File jobDirectory,
java.io.File jobScript,
boolean interactive,
@Nullable
java.lang.Integer timeout,
boolean launchInJobDirectory)
throws JobLaunchException
kill call).jobDirectory - Job directoryjobScript - job script (a.k.a. run file)interactive - launch in interactive mode (inherit I/O) or batch (no input, write outputs to files)timeout - The optional number of seconds this job is allowed to run before the system will
kill itlaunchInJobDirectory - launch the job process from the job directory rather than the current directoryJobLaunchException - if the job process failed to launchvoid kill(KillService.KillSource source)
source - The KillService.KillSource value representing where this kill request is coming fromJobProcessResult waitFor() throws java.lang.InterruptedException
java.lang.IllegalStateException - if the process was not launchedjava.lang.InterruptedException - if the calling thread is interrupted while waiting