T - the type of the task of the jobpublic interface Job<T extends Task<?>>
| Modifier and Type | Method and Description |
|---|---|
void |
failJob(AlluxioRuntimeException reason)
set job as failure with exception.
|
JobDescription |
getDescription() |
java.util.OptionalLong |
getEndTime() |
java.lang.String |
getJobId() |
JobState |
getJobState() |
java.util.Optional<T> |
getNextTask(WorkerInfo worker) |
java.lang.String |
getProgress(JobProgressReportFormat format,
boolean verbose)
Get job progress.
|
void |
initiateVerification()
Initiate a verification pass.
|
boolean |
isCurrentPassDone()
Check whether the current pass is finished.
|
boolean |
isDone()
Check whether the job is finished.
|
boolean |
isHealthy()
Check whether the job is healthy.
|
boolean |
isRunning()
Check whether the job is still running.
|
boolean |
needVerification() |
boolean |
processResponse(T task)
process task result.
|
void |
setJobState(JobState state)
set job state.
|
void |
setJobSuccess()
set job as success.
|
Journal.JournalEntry |
toJournalEntry() |
void |
updateJob(Job<?> job)
update job configs.
|
JobDescription getDescription()
java.util.OptionalLong getEndTime()
boolean needVerification()
JobState getJobState()
void setJobState(JobState state)
state - job statejava.lang.String getJobId()
void failJob(AlluxioRuntimeException reason)
reason - exceptionvoid setJobSuccess()
java.lang.String getProgress(JobProgressReportFormat format, boolean verbose)
format - progress report formatverbose - whether to include detailed informationjava.lang.IllegalArgumentException - if the format is not supportedboolean isHealthy()
boolean isRunning()
boolean isDone()
boolean isCurrentPassDone()
void initiateVerification()
java.util.Optional<T> getNextTask(WorkerInfo worker)
worker - blocker to workerAlluxioRuntimeException - if any error occurs when getting next taskJournal.JournalEntry toJournalEntry()
boolean processResponse(T task)
task - task containing result futurevoid updateJob(Job<?> job)
job - the job to update from. Must be the same job typeCopyright © 2024. All Rights Reserved.