|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.hadoop.mapred.JobHistory.JobInfo
public static class JobHistory.JobInfo
Helper class for logging or reading back events related to job start, finish or failure.
| Constructor Summary | |
|---|---|
JobHistory.JobInfo(String jobId)
Create new JobInfo |
|
| Method Summary | |
|---|---|
String |
get(JobHistory.Keys k)
Get 'String' value for given key. |
Map<String,JobHistory.Task> |
getAllTasks()
Returns all map and reduce tasks |
int |
getInt(JobHistory.Keys k)
Convert value from history to int and return. |
static String |
getLocalJobFilePath(String jobId)
Get the path of the locally stored job file |
long |
getLong(JobHistory.Keys k)
Convert value from history to int and return. |
Map<JobHistory.Keys,String> |
getValues()
Returns Map containing all key-values. |
void |
handle(Map<JobHistory.Keys,String> values)
Reads values back from the history, input is same Map as passed to Listener by parseHistory(). |
static void |
logFailed(String jobid,
long timestamp,
int finishedMaps,
int finishedReduces)
Logs job failed event. |
static void |
logFinished(String jobId,
long finishTime,
int finishedMaps,
int finishedReduces,
int failedMaps,
int failedReduces,
Counters counters)
Log job finished. |
static void |
logStarted(String jobId,
long startTime,
int totalMaps,
int totalReduces)
Logs launch time of job. |
static void |
logSubmitted(String jobId,
JobConf jobConf,
String jobConfPath,
long submitTime)
Log job submitted event to history. |
void |
set(JobHistory.Keys k,
String s)
Set value for the key. |
void |
set(Map<JobHistory.Keys,String> m)
Adds all values in the Map argument to its own values. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JobHistory.JobInfo(String jobId)
| Method Detail |
|---|
public Map<String,JobHistory.Task> getAllTasks()
public static String getLocalJobFilePath(String jobId)
jobId - id of the job
public static void logSubmitted(String jobId,
JobConf jobConf,
String jobConfPath,
long submitTime)
jobId - job id assigned by job tracker.jobConf - job conf of the jobjobConfPath - path to job conf xml file in HDFS.submitTime - time when job tracker received the job
public static void logStarted(String jobId,
long startTime,
int totalMaps,
int totalReduces)
jobId - job id, assigned by jobtracker.startTime - start time of job.totalMaps - total maps assigned by jobtracker.totalReduces - total reduces.
public static void logFinished(String jobId,
long finishTime,
int finishedMaps,
int finishedReduces,
int failedMaps,
int failedReduces,
Counters counters)
jobId - job id, assigned by jobtracker.finishTime - finish time of job in ms.finishedMaps - no of maps successfully finished.finishedReduces - no of reduces finished sucessfully.failedMaps - no of failed map tasks.failedReduces - no of failed reduce tasks.counters - the counters from the job
public static void logFailed(String jobid,
long timestamp,
int finishedMaps,
int finishedReduces)
jobid - job idtimestamp - time when job failure was detected in ms.finishedMaps - no finished map tasks.finishedReduces - no of finished reduce tasks.public String get(JobHistory.Keys k)
k -
public int getInt(JobHistory.Keys k)
k - keypublic long getLong(JobHistory.Keys k)
k -
public void set(JobHistory.Keys k,
String s)
k - s - public void set(Map<JobHistory.Keys,String> m)
m - public void handle(Map<JobHistory.Keys,String> values)
values - public Map<JobHistory.Keys,String> getValues()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||