Interface ExternalSynchronization
- All Superinterfaces:
 Serializable
- All Known Implementing Classes:
 HDFSSynchronization
Provides mechanism for acquiring locks related to the job. Serves as source of unique events
 among the job.
- 
Method Summary
Modifier and TypeMethodDescriptionorg.apache.hadoop.mapreduce.TaskAttemptIDacquireTaskAttemptIdLock(org.apache.hadoop.conf.Configuration conf, int taskId) Creates uniqueTaskAttemptIDfor given taskId.org.apache.hadoop.mapreduce.TaskIDacquireTaskIdLock(org.apache.hadoop.conf.Configuration conf) CreatesTaskIDwith unique id among given job.voidreleaseJobIdLock(org.apache.hadoop.conf.Configuration conf) Deletes lock ids bounded with given job if any exists.booleantryAcquireJobLock(org.apache.hadoop.conf.Configuration conf) Tries to acquire lock for given job. 
- 
Method Details
- 
tryAcquireJobLock
boolean tryAcquireJobLock(org.apache.hadoop.conf.Configuration conf) Tries to acquire lock for given job.- Parameters:
 conf- configuration bounded with given job.- Returns:
 trueif the lock was acquired,falseotherwise.
 - 
releaseJobIdLock
void releaseJobIdLock(org.apache.hadoop.conf.Configuration conf) Deletes lock ids bounded with given job if any exists.- Parameters:
 conf- hadoop configuration of given job.
 - 
acquireTaskIdLock
org.apache.hadoop.mapreduce.TaskID acquireTaskIdLock(org.apache.hadoop.conf.Configuration conf) CreatesTaskIDwith unique id among given job.- Parameters:
 conf- hadoop configuration of given job.- Returns:
 TaskIDwith unique id among given job.
 - 
acquireTaskAttemptIdLock
org.apache.hadoop.mapreduce.TaskAttemptID acquireTaskAttemptIdLock(org.apache.hadoop.conf.Configuration conf, int taskId) Creates uniqueTaskAttemptIDfor given taskId.- Parameters:
 conf- configuration of given task and jobtaskId- id of the task- Returns:
 - Unique 
TaskAttemptIDfor given taskId. 
 
 -