public class JobState extends Object
Constructor and Description |
---|
JobState(String id,
org.apache.hadoop.conf.Configuration conf) |
Modifier and Type | Method and Description |
---|---|
void |
addChild(String jobid)
Add a jobid to the list of children of this job.
|
void |
close()
For storage methods that require a connection, this is a hint
that it's time to close the connection.
|
void |
delete() |
String |
getCallback()
The url callback
|
List<JobState> |
getChildren()
Get a list of jobstates for jobs that are children of this job.
|
String |
getCompleteStatus()
The status of a job once it is completed.
|
Long |
getCreated()
When this job was created.
|
Long |
getExitValue()
The system exit value of the job.
|
String |
getField(String name) |
String |
getId()
This job id.
|
static List<String> |
getJobs(org.apache.hadoop.conf.Configuration conf)
Get an id for each currently existing job, which can be used to create
a JobState object.
|
Long |
getLongField(String name)
Fetch an integer field from the store.
|
Long |
getNotifiedTime()
The time when the callback was sent.
|
String |
getParent() |
String |
getPercentComplete()
The percent complete of a job
|
static TempletonStorage |
getStorage(org.apache.hadoop.conf.Configuration conf)
Get an open instance of the selected storage class.
|
static TempletonStorage |
getStorageInstance(org.apache.hadoop.conf.Configuration conf)
Get an instance of the selected storage class.
|
String |
getUser()
The user who started this job.
|
Map<String,Object> |
getUserArgs() |
void |
setCallback(String callback) |
void |
setCompleteStatus(String complete) |
void |
setCreated(long created) |
void |
setExitValue(long exitValue) |
void |
setField(String name,
String val)
Store a String field from the store.
|
void |
setLongField(String name,
long val)
Store a long field.
|
void |
setNotifiedTime(long notified) |
void |
setParent(String id)
Set parent job of this job
|
void |
setPercentComplete(String percent) |
void |
setUser(String user) |
void |
setUserArgs(Map<String,Object> userArgs) |
public JobState(String id, org.apache.hadoop.conf.Configuration conf) throws IOException
IOException
public void delete() throws IOException
IOException
public static TempletonStorage getStorageInstance(org.apache.hadoop.conf.Configuration conf)
public static TempletonStorage getStorage(org.apache.hadoop.conf.Configuration conf) throws IOException
IOException
public void close() throws IOException
IOException
public String getId()
public String getPercentComplete() throws IOException
IOException
public void setPercentComplete(String percent) throws IOException
IOException
public void addChild(String jobid) throws IOException
jobid
- IOException
public void setParent(String id) throws IOException
id
- IOException
public String getParent() throws IOException
IOException
public List<JobState> getChildren() throws IOException
IOException
public Long getExitValue() throws IOException
IOException
public void setExitValue(long exitValue) throws IOException
IOException
public Long getCreated() throws IOException
IOException
public void setCreated(long created) throws IOException
IOException
public String getUser() throws IOException
IOException
public void setUser(String user) throws IOException
IOException
public Map<String,Object> getUserArgs() throws IOException
IOException
public void setUserArgs(Map<String,Object> userArgs) throws IOException
IOException
public String getCallback() throws IOException
IOException
public void setCallback(String callback) throws IOException
IOException
public String getCompleteStatus() throws IOException
IOException
public void setCompleteStatus(String complete) throws IOException
IOException
public Long getNotifiedTime() throws IOException
IOException
public void setNotifiedTime(long notified) throws IOException
IOException
public Long getLongField(String name) throws IOException
IOException
public void setField(String name, String val) throws IOException
IOException
public String getField(String name) throws IOException
IOException
public void setLongField(String name, long val) throws IOException
name
- val
- IOException
public static List<String> getJobs(org.apache.hadoop.conf.Configuration conf) throws IOException
conf
- IOException
Copyright © 2017 The Apache Software Foundation. All rights reserved.