当前位置: 首页>>代码示例>>Java>>正文


Java TaskID.forName方法代码示例

本文整理汇总了Java中org.apache.hadoop.mapreduce.TaskID.forName方法的典型用法代码示例。如果您正苦于以下问题:Java TaskID.forName方法的具体用法?Java TaskID.forName怎么用?Java TaskID.forName使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.hadoop.mapreduce.TaskID的用法示例。


在下文中一共展示了TaskID.forName方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setDatum

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
public void setDatum(Object odatum) {
  this.datum = (TaskFailed)odatum;
  this.id =
      TaskID.forName(datum.taskid.toString());
  this.taskType =
      TaskType.valueOf(datum.taskType.toString());
  this.finishTime = datum.finishTime;
  this.error = datum.error.toString();
  this.failedDueToAttempt =
      datum.failedDueToAttempt == null
      ? null
      : TaskAttemptID.forName(
          datum.failedDueToAttempt.toString());
  this.status = datum.status.toString();
  this.counters =
      EventReader.fromAvro(datum.counters);
}
 
开发者ID:naver,项目名称:hadoop,代码行数:18,代码来源:TaskFailedEvent.java

示例2: setDatum

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
public void setDatum(Object oDatum) {
  this.datum = (TaskFinished)oDatum;
  this.taskid = TaskID.forName(datum.taskid.toString());
  if (datum.successfulAttemptId != null) {
    this.successfulAttemptId = TaskAttemptID
        .forName(datum.successfulAttemptId.toString());
  }
  this.finishTime = datum.finishTime;
  this.taskType = TaskType.valueOf(datum.taskType.toString());
  this.status = datum.status.toString();
  this.counters = EventReader.fromAvro(datum.counters);
}
 
开发者ID:naver,项目名称:hadoop,代码行数:13,代码来源:TaskFinishedEvent.java

示例3: maybeEmitEvent

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
HistoryEvent maybeEmitEvent(ParsedLine line, String taskIDName,
    HistoryEventEmitter thatg) {
  if (taskIDName == null) {
    return null;
  }

  TaskID taskID = TaskID.forName(taskIDName);

  String taskType = line.get("TASK_TYPE");
  String startTime = line.get("START_TIME");
  String splits = line.get("SPLITS");

  if (startTime != null && taskType != null) {
    Task20LineHistoryEventEmitter that =
        (Task20LineHistoryEventEmitter) thatg;

    that.originalStartTime = Long.parseLong(startTime);
    that.originalTaskType =
        Version20LogInterfaceUtils.get20TaskType(taskType);

    return new TaskStartedEvent(taskID, that.originalStartTime,
        that.originalTaskType, splits);
  }

  return null;
}
 
开发者ID:naver,项目名称:hadoop,代码行数:27,代码来源:Task20LineHistoryEventEmitter.java

示例4: setDatum

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
public void setDatum(Object odatum) {
  this.datum = (TaskFailed)odatum;
  this.id =
      TaskID.forName(datum.getTaskid().toString());
  this.taskType =
      TaskType.valueOf(datum.getTaskType().toString());
  this.finishTime = datum.getFinishTime();
  this.error = datum.getError().toString();
  this.failedDueToAttempt =
      datum.getFailedDueToAttempt() == null
      ? null
      : TaskAttemptID.forName(
          datum.getFailedDueToAttempt().toString());
  this.status = datum.getStatus().toString();
  this.counters =
      EventReader.fromAvro(datum.getCounters());
}
 
开发者ID:aliyun-beta,项目名称:aliyun-oss-hadoop-fs,代码行数:18,代码来源:TaskFailedEvent.java

示例5: setDatum

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
public void setDatum(Object oDatum) {
  this.datum = (TaskFinished)oDatum;
  this.taskid = TaskID.forName(datum.getTaskid().toString());
  if (datum.getSuccessfulAttemptId() != null) {
    this.successfulAttemptId = TaskAttemptID
        .forName(datum.getSuccessfulAttemptId().toString());
  }
  this.finishTime = datum.getFinishTime();
  this.taskType = TaskType.valueOf(datum.getTaskType().toString());
  this.status = datum.getStatus().toString();
  this.counters = EventReader.fromAvro(datum.getCounters());
}
 
开发者ID:aliyun-beta,项目名称:aliyun-oss-hadoop-fs,代码行数:13,代码来源:TaskFinishedEvent.java

示例6: getTaskId

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
/** Get the task id */
public TaskID getTaskId() { return TaskID.forName(datum.taskid.toString()); }
 
开发者ID:naver,项目名称:hadoop,代码行数:3,代码来源:TaskStartedEvent.java

示例7: getTaskId

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
/** Get the task ID */
public TaskID getTaskId() { return TaskID.forName(datum.taskid.toString()); }
 
开发者ID:naver,项目名称:hadoop,代码行数:3,代码来源:TaskUpdatedEvent.java

示例8: setTaskID

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
void setTaskID(String taskID) {
  this.taskID = TaskID.forName(taskID);
}
 
开发者ID:naver,项目名称:hadoop,代码行数:4,代码来源:LoggedTask.java

示例9: getTaskId

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
/** Get the task id */
public TaskID getTaskId() {
  return TaskID.forName(datum.getTaskid().toString());
}
 
开发者ID:aliyun-beta,项目名称:aliyun-oss-hadoop-fs,代码行数:5,代码来源:TaskStartedEvent.java

示例10: getTaskId

import org.apache.hadoop.mapreduce.TaskID; //导入方法依赖的package包/类
/** Get the task ID */
public TaskID getTaskId() {
  return TaskID.forName(datum.getTaskid().toString());
}
 
开发者ID:aliyun-beta,项目名称:aliyun-oss-hadoop-fs,代码行数:5,代码来源:TaskUpdatedEvent.java


注:本文中的org.apache.hadoop.mapreduce.TaskID.forName方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。