Package com.netflix.genie.common.dto
Class JobExecution
- java.lang.Object
-
- com.netflix.genie.common.dto.BaseDTO
-
- com.netflix.genie.common.dto.JobExecution
-
- All Implemented Interfaces:
java.io.Serializable
public class JobExecution extends BaseDTO
All information needed to show state of a running job.- Since:
- 3.0.0
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
JobExecution.Builder
A builder to create job requests.
-
Field Summary
Fields Modifier and Type Field Description static int
KILLED_EXIT_CODE
The exit code that will be set to indicate a job is killed.static int
LOST_EXIT_CODE
The exit code that will be set to indicate a job is has been lost by Genie.static int
SUCCESS_EXIT_CODE
The exit code that will be set to indicate a job has succeeded.
-
Constructor Summary
Constructors Modifier Constructor Description protected
JobExecution(JobExecution.Builder builder)
Constructor used by the builder build() method.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Optional<ArchiveStatus>
getArchiveStatus()
Get the archival status of job files.java.util.Optional<java.lang.Long>
getCheckDelay()
Get the amount of time (in milliseconds) to delay between checks of status of the job process.java.util.Optional<java.lang.Integer>
getExitCode()
Get the exit code of the process.java.util.Optional<com.fasterxml.jackson.databind.JsonNode>
getLauncherExt()
Get the launcher extension.java.util.Optional<java.lang.Integer>
getMemory()
Get the amount of memory (in MB) of the job.java.util.Optional<java.lang.Integer>
getProcessId()
Get the process id for this job execution as Optional.java.util.Optional<java.time.Instant>
getTimeout()
Get the timeout date for this job after which if it is still running the system will attempt to kill it.-
Methods inherited from class com.netflix.genie.common.dto.BaseDTO
getCreated, getId, getUpdated, toString
-
-
-
-
Field Detail
-
KILLED_EXIT_CODE
public static final int KILLED_EXIT_CODE
The exit code that will be set to indicate a job is killed.- See Also:
- Constant Field Values
-
LOST_EXIT_CODE
public static final int LOST_EXIT_CODE
The exit code that will be set to indicate a job is has been lost by Genie.- See Also:
- Constant Field Values
-
SUCCESS_EXIT_CODE
public static final int SUCCESS_EXIT_CODE
The exit code that will be set to indicate a job has succeeded.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
JobExecution
protected JobExecution(JobExecution.Builder builder)
Constructor used by the builder build() method.- Parameters:
builder
- The builder to use
-
-
Method Detail
-
getProcessId
public java.util.Optional<java.lang.Integer> getProcessId()
Get the process id for this job execution as Optional.- Returns:
- The process id
-
getCheckDelay
public java.util.Optional<java.lang.Long> getCheckDelay()
Get the amount of time (in milliseconds) to delay between checks of status of the job process.- Returns:
- The time to delay as an Optional as it could be null
-
getTimeout
public java.util.Optional<java.time.Instant> getTimeout()
Get the timeout date for this job after which if it is still running the system will attempt to kill it.- Returns:
- The timeout date
-
getExitCode
public java.util.Optional<java.lang.Integer> getExitCode()
Get the exit code of the process.- Returns:
- The exit code as an Optional as it could be null
-
getMemory
public java.util.Optional<java.lang.Integer> getMemory()
Get the amount of memory (in MB) of the job.- Returns:
- The amount of memory the job is set to use as an Optional as it could be null
-
getArchiveStatus
public java.util.Optional<ArchiveStatus> getArchiveStatus()
Get the archival status of job files.- Returns:
- the archival status as Optional as it could be null
-
getLauncherExt
public java.util.Optional<com.fasterxml.jackson.databind.JsonNode> getLauncherExt()
Get the launcher extension.- Returns:
- the launcher extension as Optional as it could be null
-
-