Package org.apache.hadoop.mapred
Class JobStatus
java.lang.Object
org.apache.hadoop.mapreduce.JobStatus
org.apache.hadoop.mapred.JobStatus
Describes the current status of a job. This is
not intended to be a comprehensive piece of data.
For that, look at JobProfile.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.hadoop.mapreduce.JobStatus
JobStatus.State -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionJobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp) Deprecated.JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid.JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl, boolean isUber) Create a job status object for a given jobid.JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl, boolean isUber, String historyFile) Create a job status object for a given jobid.JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String queue, String jobFile, String trackingUrl) Create a job status object for a given jobid.JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String queue, String jobFile, String trackingUrl, boolean isUber) Create a job status object for a given jobid.JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String queue, String jobFile, String trackingUrl, boolean isUber, String historyFile) Create a job status object for a given jobid.JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState) Deprecated.JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid.JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp) Deprecated.JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid.Deprecated.JobStatus(JobID jobid, float mapProgress, float reduceProgress, int runState, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid. -
Method Summary
Modifier and TypeMethodDescriptionfloatstatic JobStatusgetJobId()Deprecated.use getJobID insteadgetJobID()Return the priority of the jobstatic StringgetJobRunState(int state) Helper method to get human-readable state of the job.intfloatfloatprotected voidsetCleanupProgress(float p) Sets the cleanup progress of this jobvoidsetFailureInfo(String failureInfo) Set diagnostic information.protected voidsetFinishTime(long finishTime) Set the finish time of the jobprotected voidsetHistoryFile(String historyFile) Set the job history file url for a completed jobprotected voidsetJobACLs(Map<org.apache.hadoop.mapreduce.JobACL, AccessControlList> acls) Set the job acls.voidSet the priority of the job, defaulting to NORMAL.protected voidsetMapProgress(float p) Sets the map progress of this jobprotected voidsetReduceProgress(float p) Sets the reduce progress of this Jobprotected voidSet the job retire flag to true.voidsetRunState(int state) Change the current run state of the job.voidsetSchedulingInfo(String schedulingInfo) Used to set the scheduling information associated to a particular Job.protected voidsetSetupProgress(float p) Sets the setup progress of this jobprotected voidsetStartTime(long startTime) Set the start time of the jobprotected voidsetTrackingUrl(String trackingUrl) Set the link to the web-ui for details of the job.floatprotected voidsetUsername(String userName) Methods inherited from class org.apache.hadoop.mapreduce.JobStatus
clone, getCleanupProgress, getFailureInfo, getFinishTime, getHistoryFile, getJobACLs, getJobFile, getJobName, getMapProgress, getNeededMem, getNumReservedSlots, getNumUsedSlots, getPriority, getQueue, getReduceProgress, getReservedMem, getSchedulingInfo, getSetupProgress, getStartTime, getState, getTrackingUrl, getUsedMem, getUsername, isJobComplete, isRetired, isUber, readFields, setNeededMem, setNumReservedSlots, setNumUsedSlots, setPriority, setQueue, setReservedMem, setState, setUber, setUsedMem, toString, write
-
Field Details
-
RUNNING
public static final int RUNNING -
SUCCEEDED
public static final int SUCCEEDED -
FAILED
public static final int FAILED -
PREP
public static final int PREP -
KILLED
public static final int KILLED
-
-
Constructor Details
-
JobStatus
public JobStatus() -
JobStatus
@Deprecated public JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState) Deprecated. -
JobStatus
Deprecated.Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducesrunState- The current state of the job
-
JobStatus
@Deprecated public JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp) Deprecated.Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducesrunState- The current state of the jobjp- Priority of the job.
-
JobStatus
@Deprecated public JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp) Deprecated.Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobsetupProgress- The progress made on the setupmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on the cleanuprunState- The current state of the jobjp- Priority of the job.
-
JobStatus
public JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on cleanuprunState- The current state of the jobuser- userid of the person who submitted the job.jobName- user-specified job name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.
-
JobStatus
public JobStatus(JobID jobid, float mapProgress, float reduceProgress, int runState, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducesrunState- The current state of the jobuser- userid of the person who submitted the job.jobName- user-specified job name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.
-
JobStatus
public JobStatus(JobID jobid, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducesrunState- The current state of the jobjp- Priority of the job.user- userid of the person who submitted the job.jobName- user-specified job name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.
-
JobStatus
public JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobsetupProgress- The progress made on the setupmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on the cleanuprunState- The current state of the jobjp- Priority of the job.user- userid of the person who submitted the job.jobName- user-specified job name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.
-
JobStatus
public JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl, boolean isUber) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobsetupProgress- The progress made on the setupmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on the cleanuprunState- The current state of the jobjp- Priority of the job.user- userid of the person who submitted the job.jobName- user-specified job name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.isUber- Whether job running in uber mode
-
JobStatus
public JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String jobFile, String trackingUrl, boolean isUber, String historyFile) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobsetupProgress- The progress made on the setupmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on the cleanuprunState- The current state of the jobjp- Priority of the job.user- userid of the person who submitted the job.jobName- user-specified job name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.isUber- Whether job running in uber modehistoryFile- history file
-
JobStatus
public JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String queue, String jobFile, String trackingUrl) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobsetupProgress- The progress made on the setupmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on the cleanuprunState- The current state of the jobjp- Priority of the job.user- userid of the person who submitted the job.jobName- user-specified job name.queue- job queue name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.
-
JobStatus
public JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String queue, String jobFile, String trackingUrl, boolean isUber) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobsetupProgress- The progress made on the setupmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on the cleanuprunState- The current state of the jobjp- Priority of the job.user- userid of the person who submitted the job.jobName- user-specified job name.queue- job queue name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.isUber- Whether job running in uber mode
-
JobStatus
public JobStatus(JobID jobid, float setupProgress, float mapProgress, float reduceProgress, float cleanupProgress, int runState, JobPriority jp, String user, String jobName, String queue, String jobFile, String trackingUrl, boolean isUber, String historyFile) Create a job status object for a given jobid.- Parameters:
jobid- The jobid of the jobsetupProgress- The progress made on the setupmapProgress- The progress made on the mapsreduceProgress- The progress made on the reducescleanupProgress- The progress made on the cleanuprunState- The current state of the jobjp- Priority of the job.user- userid of the person who submitted the job.jobName- user-specified job name.queue- job queue name.jobFile- job configuration file.trackingUrl- link to the web-ui for details of the job.isUber- Whether job running in uber modehistoryFile- history file
-
-
Method Details
-
getJobRunState
Helper method to get human-readable state of the job.- Parameters:
state- job state- Returns:
- human-readable state of the job
-
downgrade
-
getJobId
Deprecated.use getJobID instead -
getJobID
-
getJobPriority
Return the priority of the job- Returns:
- job priority
-
setMapProgress
protected void setMapProgress(float p) Sets the map progress of this job- Overrides:
setMapProgressin classJobStatus- Parameters:
p- The value of map progress to set to
-
setCleanupProgress
protected void setCleanupProgress(float p) Sets the cleanup progress of this job- Overrides:
setCleanupProgressin classJobStatus- Parameters:
p- The value of cleanup progress to set to
-
setSetupProgress
protected void setSetupProgress(float p) Sets the setup progress of this job- Overrides:
setSetupProgressin classJobStatus- Parameters:
p- The value of setup progress to set to
-
setReduceProgress
protected void setReduceProgress(float p) Sets the reduce progress of this Job- Overrides:
setReduceProgressin classJobStatus- Parameters:
p- The value of reduce progress to set to
-
setFinishTime
protected void setFinishTime(long finishTime) Set the finish time of the job- Overrides:
setFinishTimein classJobStatus- Parameters:
finishTime- The finishTime of the job
-
setHistoryFile
Set the job history file url for a completed job- Overrides:
setHistoryFilein classJobStatus
-
setTrackingUrl
Set the link to the web-ui for details of the job.- Overrides:
setTrackingUrlin classJobStatus
-
setRetired
protected void setRetired()Set the job retire flag to true.- Overrides:
setRetiredin classJobStatus
-
setRunState
@Private public void setRunState(int state) Change the current run state of the job. The setter is public to be compatible with M/R 1.x, however, it should be used internally.- Parameters:
state- the state of the job
-
getRunState
public int getRunState()- Returns:
- running state of the job
-
setStartTime
protected void setStartTime(long startTime) Set the start time of the job- Overrides:
setStartTimein classJobStatus- Parameters:
startTime- The startTime of the job
-
setUsername
- Overrides:
setUsernamein classJobStatus- Parameters:
userName- The username of the job
-
setSchedulingInfo
Used to set the scheduling information associated to a particular Job. The setter is public to be compatible with M/R 1.x, however, it should be used internally.- Overrides:
setSchedulingInfoin classJobStatus- Parameters:
schedulingInfo- Scheduling information of the job
-
setJobACLs
Description copied from class:JobStatusSet the job acls.- Overrides:
setJobACLsin classJobStatus- Parameters:
acls-MapfromJobACLtoAccessControlList
-
setFailureInfo
Description copied from class:JobStatusSet diagnostic information.- Overrides:
setFailureInfoin classJobStatus- Parameters:
failureInfo- diagnostic information
-
setJobPriority
Set the priority of the job, defaulting to NORMAL.- Parameters:
jp- new job priority
-
mapProgress
public float mapProgress()- Returns:
- Percentage of progress in maps
-
cleanupProgress
public float cleanupProgress()- Returns:
- Percentage of progress in cleanup
-
setupProgress
public float setupProgress()- Returns:
- Percentage of progress in setup
-
reduceProgress
public float reduceProgress()- Returns:
- Percentage of progress in reduce
-