/** * Invoke getConfiguration() on JobContext. Works with both * Hadoop 1 and 2. */ public static Configuration getConfiguration(JobContext context) { return (Configuration) invoke(GET_CONFIGURATION_METHOD, context); }
/** * Invoke setStatus() on TaskAttemptContext. Works with both * Hadoop 1 and 2. */ public static void setStatus(TaskAttemptContext context, String status) { invoke(SET_STATUS_METHOD, context, status); }
/** * returns TaskAttemptContext.getTaskAttemptID(). Works with both * Hadoop 1 and 2. */ public static TaskAttemptID getTaskAttemptID(TaskAttemptContext taskContext) { return (TaskAttemptID) invoke(GET_TASK_ATTEMPT_ID, taskContext); }
/** * Invoke TaskAttemptContext.progress(). Works with both * Hadoop 1 and 2. */ public static void progress(TaskAttemptContext context) { invoke(PROGRESS_METHOD, context); }
/** * Increment the counter. Works with both Hadoop 1 and 2 */ public static void incrementCounter(Counter counter, long increment) { // incrementing a count might be called often. Might be affected by // cost of invoke(). might be good candidate to handle in a shim. // (TODO Raghu) figure out how achieve such a build with maven invoke(INCREMENT_COUNTER_METHOD, counter, increment); } }
/** * Invoke setStatus() on TaskAttemptContext. Works with both * Hadoop 1 and 2. */ public static void setStatus(TaskAttemptContext context, String status) { invoke(SET_STATUS_METHOD, context, status); }
/** * Invoke TaskAttemptContext.progress(). Works with both * Hadoop 1 and 2. */ public static void progress(TaskAttemptContext context) { invoke(PROGRESS_METHOD, context); }
/** * Invoke TaskAttemptContext.progress(). Works with both * Hadoop 1 and 2. */ public static void progress(TaskAttemptContext context) { invoke(PROGRESS_METHOD, context); }
/** * Invoke getConfiguration() on JobContext. Works with both * Hadoop 1 and 2. */ public static Configuration getConfiguration(JobContext context) { return (Configuration) invoke(GET_CONFIGURATION_METHOD, context); }
/** * returns TaskAttemptContext.getTaskAttemptID(). Works with both * Hadoop 1 and 2. */ public static TaskAttemptID getTaskAttemptID(TaskAttemptContext taskContext) { return (TaskAttemptID) invoke(GET_TASK_ATTEMPT_ID, taskContext); }
/** * Invoke getConfiguration() on JobContext. Works with both * Hadoop 1 and 2. */ public static Configuration getConfiguration(JobContext context) { return (Configuration) invoke(GET_CONFIGURATION_METHOD, context); }
/** * Invoke getCounter() on TaskInputOutputContext. Works with both * Hadoop 1 and 2. */ public static Counter getCounter(TaskInputOutputContext context, String groupName, String counterName) { return (Counter) invoke(GET_COUNTER_METHOD, context, groupName, counterName); }
/** * returns TaskAttemptContext.getTaskAttemptID(). Works with both * Hadoop 1 and 2. */ public static TaskAttemptID getTaskAttemptID(TaskAttemptContext taskContext) { return (TaskAttemptID) invoke(GET_TASK_ATTEMPT_ID, taskContext); }
/** * Increment the counter. Works with both Hadoop 1 and 2 */ public static void incrementCounter(Counter counter, long increment) { // incrementing a count might be called often. Might be affected by // cost of invoke(). might be good candidate to handle in a shim. // (TODO Raghu) figure out how achieve such a build with maven invoke(INCREMENT_COUNTER_METHOD, counter, increment); } }
/** * Invoke getCounter() on TaskInputOutputContext. Works with both * Hadoop 1 and 2. */ public static Counter getCounter(TaskInputOutputContext context, String groupName, String counterName) { return (Counter) invoke(GET_COUNTER_METHOD, context, groupName, counterName); }
/** * Invoke getCounter() on TaskInputOutputContext. Works with both * Hadoop 1 and 2. */ public static Counter getCounter(TaskInputOutputContext context, String groupName, String counterName) { return (Counter) invoke(GET_COUNTER_METHOD, context, groupName, counterName); }
/** * Invoke getConfiguration() on JobContext. Works with both * Hadoop 1 and 2. */ public static Configuration getConfiguration(JobContext context) { return (Configuration) invoke(GET_CONFIGURATION_METHOD, context); }
/** * Invoke setStatus() on TaskAttemptContext. Works with both * Hadoop 1 and 2. */ public static void setStatus(TaskAttemptContext context, String status) { invoke(SET_STATUS_METHOD, context, status); }
/** * Invoke getCounter() on TaskInputOutputContext. Works with both * Hadoop 1 and 2. */ public static Counter getCounter(TaskInputOutputContext context, String groupName, String counterName) { return (Counter) invoke(GET_COUNTER_METHOD, context, groupName, counterName); }
/** * Increment the counter. Works with both Hadoop 1 and 2 */ public static void incrementCounter(Counter counter, long increment) { // incrementing a count might be called often. Might be affected by // cost of invoke(). might be good candidate to handle in a shim. // (TODO Raghu) figure out how achieve such a build with maven invoke(INCREMENT_COUNTER_METHOD, counter, increment); } }