|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.mapred.JobTracker
JobTracker is the central location for submitting and tracking MR jobs in a network environment.
Field Summary | |
static int |
FILE_NOT_FOUND
|
static long |
HEARTBEAT_INTERVAL
|
static org.apache.commons.logging.Log |
LOG
|
static int |
SUCCESS
|
static long |
TASKTRACKER_EXPIRY_INTERVAL
|
static int |
TRACKERS_OK
|
static int |
UNKNOWN_TASKTRACKER
|
Method Summary | |
Vector |
completedJobs()
|
int |
emitHeartbeat(org.apache.hadoop.mapred.TaskTrackerStatus trackerStatus,
boolean initialContact)
Process incoming heartbeat messages from the task trackers. |
Vector |
failedJobs()
|
static InetSocketAddress |
getAddress(Configuration conf)
|
ClusterStatus |
getClusterStatus()
Get the current status of the cluster |
String |
getFilesystemName()
Grab the local fs name |
int |
getInfoPort()
|
org.apache.hadoop.mapred.JobInProgress |
getJob(String jobid)
|
org.apache.hadoop.mapred.JobProfile |
getJobProfile(String jobid)
Grab a handle to a job that is already known to the JobTracker |
org.apache.hadoop.mapred.JobStatus |
getJobStatus(String jobid)
Grab a handle to a job that is already known to the JobTracker |
String |
getJobTrackerMachine()
|
TaskReport[] |
getMapTaskReports(String jobid)
Grab a bunch of info on the tasks that make up the job |
TaskReport[] |
getReduceTaskReports(String jobid)
|
long |
getStartTime()
|
org.apache.hadoop.mapred.TaskTrackerStatus |
getTaskTracker(String trackerID)
|
int |
getTotalSubmissions()
|
static JobTracker |
getTracker()
|
int |
getTrackerPort()
|
void |
killJob(String jobid)
Kill the indicated job |
org.apache.hadoop.mapred.MapOutputLocation[] |
locateMapOutputs(String jobId,
int[] mapTasksNeeded,
int reduce)
A TaskTracker wants to know the physical locations of completed, but not yet closed, tasks. |
static void |
main(String[] argv)
Start the JobTracker process. |
void |
offerService()
Run forever |
org.apache.hadoop.mapred.Task |
pollForNewTask(String taskTracker)
A tracker wants to know if there's a Task to run. |
String[] |
pollForTaskWithClosedJob(String taskTracker)
A tracker wants to know if any of its Tasks have been closed (because the job completed, whether successfully or not) |
void |
reportTaskTrackerError(String taskTracker,
String errorClass,
String errorMessage)
Report a problem to the job tracker. |
Vector |
runningJobs()
|
static void |
startTracker(Configuration conf)
|
org.apache.hadoop.mapred.JobStatus |
submitJob(String jobFile)
JobTracker.submitJob() kicks off a new job. |
Collection |
taskTrackers()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final org.apache.commons.logging.Log LOG
public static final long HEARTBEAT_INTERVAL
public static final long TASKTRACKER_EXPIRY_INTERVAL
public static final int SUCCESS
public static final int FILE_NOT_FOUND
public static final int TRACKERS_OK
public static final int UNKNOWN_TASKTRACKER
Method Detail |
public static void startTracker(Configuration conf) throws IOException
IOException
public static JobTracker getTracker()
public static InetSocketAddress getAddress(Configuration conf)
public void offerService()
public int getTotalSubmissions()
public String getJobTrackerMachine()
public int getTrackerPort()
public int getInfoPort()
public long getStartTime()
public Vector runningJobs()
public Vector failedJobs()
public Vector completedJobs()
public Collection taskTrackers()
public org.apache.hadoop.mapred.TaskTrackerStatus getTaskTracker(String trackerID)
public int emitHeartbeat(org.apache.hadoop.mapred.TaskTrackerStatus trackerStatus, boolean initialContact)
emitHeartbeat
in interface org.apache.hadoop.mapred.InterTrackerProtocol
public org.apache.hadoop.mapred.Task pollForNewTask(String taskTracker)
pollForNewTask
in interface org.apache.hadoop.mapred.InterTrackerProtocol
public String[] pollForTaskWithClosedJob(String taskTracker)
pollForTaskWithClosedJob
in interface org.apache.hadoop.mapred.InterTrackerProtocol
public org.apache.hadoop.mapred.MapOutputLocation[] locateMapOutputs(String jobId, int[] mapTasksNeeded, int reduce)
locateMapOutputs
in interface org.apache.hadoop.mapred.InterTrackerProtocol
jobId
- the job idmapTasksNeeded
- an array of the mapIds that we needreduce
- the reduce's id
public String getFilesystemName() throws IOException
getFilesystemName
in interface org.apache.hadoop.mapred.InterTrackerProtocol
IOException
public void reportTaskTrackerError(String taskTracker, String errorClass, String errorMessage) throws IOException
org.apache.hadoop.mapred.InterTrackerProtocol
reportTaskTrackerError
in interface org.apache.hadoop.mapred.InterTrackerProtocol
taskTracker
- the name of the task trackererrorClass
- the kind of error (eg. the class that was thrown)errorMessage
- the human readable error message
IOException
- if there was a problem in communication or on the
remote sidepublic org.apache.hadoop.mapred.JobStatus submitJob(String jobFile) throws IOException
submitJob
in interface org.apache.hadoop.mapred.JobSubmissionProtocol
IOException
public ClusterStatus getClusterStatus()
org.apache.hadoop.mapred.JobSubmissionProtocol
getClusterStatus
in interface org.apache.hadoop.mapred.JobSubmissionProtocol
public void killJob(String jobid)
org.apache.hadoop.mapred.JobSubmissionProtocol
killJob
in interface org.apache.hadoop.mapred.JobSubmissionProtocol
public org.apache.hadoop.mapred.JobProfile getJobProfile(String jobid)
org.apache.hadoop.mapred.JobSubmissionProtocol
getJobProfile
in interface org.apache.hadoop.mapred.JobSubmissionProtocol
public org.apache.hadoop.mapred.JobStatus getJobStatus(String jobid)
org.apache.hadoop.mapred.JobSubmissionProtocol
getJobStatus
in interface org.apache.hadoop.mapred.JobSubmissionProtocol
public TaskReport[] getMapTaskReports(String jobid)
org.apache.hadoop.mapred.JobSubmissionProtocol
getMapTaskReports
in interface org.apache.hadoop.mapred.JobSubmissionProtocol
public TaskReport[] getReduceTaskReports(String jobid)
getReduceTaskReports
in interface org.apache.hadoop.mapred.JobSubmissionProtocol
public org.apache.hadoop.mapred.JobInProgress getJob(String jobid)
public static void main(String[] argv) throws IOException, InterruptedException
IOException
InterruptedException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |