public class UnixProcessChecker extends java.lang.Object implements ProcessChecker
Constructor and Description |
---|
UnixProcessChecker(int pid,
org.apache.commons.exec.Executor executor,
java.util.Date timeout)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
checkProcess()
Check the status of the process the process checker was constructed to check.
|
public UnixProcessChecker(@Min(value=1L) int pid, @NotNull org.apache.commons.exec.Executor executor, @NotNull java.util.Date timeout)
pid
- The process id to check.executor
- The executor to use for generating system commands.timeout
- The time which after this job should be killed due to timeoutpublic void checkProcess() throws GenieTimeoutException, org.apache.commons.exec.ExecuteException, java.io.IOException
checkProcess
in interface ProcessChecker
GenieTimeoutException
- When the process has been running longer than its configured timeout periodorg.apache.commons.exec.ExecuteException
- When the check returns a non-successful exit codejava.io.IOException
- For any other problem