|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.bigdata.service.mapred.JobState<M>
public class JobState<M>
Job state that is relevant to this service.
| Field Summary | |
|---|---|
Map<UUID,Future<Object>> |
futures
The running tasks for this job. |
BlockingQueue<Outcome> |
outcomes
The Outcomes for the completed tasks. |
| Constructor Summary | |
|---|---|
JobState(UUID uuid,
M metadata,
IBigdataClient client)
|
|
| Method Summary | |
|---|---|
boolean |
cancel(UUID task)
Cancel the task if it is running. |
void |
cancelAll()
Cancel all running tasks for this job. |
UUID |
getUUID()
The job identifier. |
String |
status()
A human readable summary of the JobState. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public Map<UUID,Future<Object>> futures
Future for that task.
FIXME reduce visibility - exposed for some unit tests.
public BlockingQueue<Outcome> outcomes
Outcomes for the completed tasks. Outcomes are
placed into this queue by the AbstractJobAndTaskService.AbstractTaskWorker.
FIXME reduce visibility - exposed for some unit tests.
| Constructor Detail |
|---|
public JobState(UUID uuid,
M metadata,
IBigdataClient client)
| Method Detail |
|---|
public UUID getUUID()
public void cancelAll()
Note: The job MUST be cancelled first since otherwise tasks could continue to be queued while this method is running.
Note: Outcomes are discarded when the job is cancelled.
public boolean cancel(UUID task)
task - The task identifier.
public String status()
JobState.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||