Examples of TaskType


Examples of com.google.devtools.moe.client.tasks.TaskType

    // This needs to get called first, so that DirectiveFactory can report
    // errors appropriately.
    AppContext.init();

    TaskType t = TaskType.TASK_MAP.get(args[0]);
    if (t == null) {
      // We did not find a task for this name. We should print help and quit.
      // But because we are in the process of converting from the old Directive framework to
      // the new Task framework, we may instead have to run oldMain. Therefore, don't
      // System.exit; just return.
      // TODO(dbentley): kill all Directives, print the relevant help, and exit instead
      // of calling directiveMain().
      try {
        directiveMain(args);
      } catch (IOException e) {
        System.exit(1);
        return;
      }
      return;
    }

    // Strip off the task name
    // This mutates t.getOptions, and so has to be called before we create the injector.
    Flags.parseOptions(t.getOptions(), ImmutableList.copyOf(args).subList(1, args.length));
    Injector injector = Guice.createInjector(t, new MoeModule());
    Task task = injector.getInstance(Task.class);

    Task.Explanation result = task.executeAtTopLevel();
    if (!Strings.isNullOrEmpty(result.message)) {
View Full Code Here

Examples of com.microsoft.windowsazure.services.media.implementation.content.TaskType

         * @param taskBody
         *            the task body
         */
        public CreateBatchOperation(String mediaProcessorId, String taskBody) {
            this.setVerb("POST");
            taskType = new TaskType();
            addContentObject(taskType);
            this.taskType.setMediaProcessorId(mediaProcessorId);
            this.taskType.setTaskBody(taskBody);
        }
View Full Code Here

Examples of edu.neu.ccs.task.TaskType

    String pname = getPrefixedName();
    TaskModelSet e = getModelSet();
    if ( ! checkTaskType(e, errors))
      return;
   
    TaskType tt = e.getTaskType(task);
    Set<String> outs = new HashSet<String>();
    for (Slot out : tt.getDeclaredOutputs())
      outs.add(out.getName());

    for (Result r : bindings) {
      if (r.check(e, pname, tt, errors))
        if (! outs.remove(r.getDestination()))
View Full Code Here

Examples of net.sf.mpxj.TaskType

    * @param value string value
    * @return TaskType value
    */
   private TaskType getTaskType(String value)
   {
      TaskType result = TaskType.FIXED_UNITS;
      if (value != null && value.equals("fixed-duration"))
      {
         result = TaskType.FIXED_DURATION;
      }
      return (result);
View Full Code Here

Examples of org.apache.hadoop.mapreduce.TaskType

   * scaled according to locality in simulation and locality in trace.
   */
  @Override
  public TaskAttemptInfo getMapTaskAttemptInfoAdjusted(int taskNumber,
      int taskAttemptNumber, int locality) {
    TaskType taskType = TaskType.MAP;
    LoggedTask loggedTask = getLoggedTask(taskType, taskNumber);
    if (loggedTask == null) {
      // TODO insert parameters
      TaskInfo taskInfo = new TaskInfo(0, 0, 0, 0, 0);
      return makeUpTaskAttemptInfo(taskType, taskInfo, taskAttemptNumber,
View Full Code Here

Examples of org.apache.hadoop.mapreduce.TaskType

        break; // This is the only exit of the while (true) loop
      }

      // Determine which task type to assign this time
      // First try choosing a task type which is not rejected
      TaskType taskType;
      if (mapRejected) {
        taskType = TaskType.REDUCE;
      } else if (reduceRejected) {
        taskType = TaskType.MAP;
      } else {
View Full Code Here

Examples of org.apache.hadoop.mapreduce.TaskType

   */
  private void preemptTasks(List<PoolSchedulable> scheds, int tasksToPreempt) {
    if (scheds.isEmpty() || tasksToPreempt == 0)
      return;
   
    TaskType taskType = scheds.get(0).getTaskType();
   
    // Collect running tasks of our type from over-scheduled pools
    List<TaskStatus> runningTasks = new ArrayList<TaskStatus>();
    for (PoolSchedulable sched: scheds) {
      if (sched.getRunningTasks() > sched.getFairShare())
View Full Code Here

Examples of org.apache.hadoop.mapreduce.TaskType

        JobContext newContext = new JobContextImpl(conf, jobId);
        return newContext;
    }

    static public boolean isMap(TaskAttemptID taskAttemptID) {
        TaskType type = taskAttemptID.getTaskType();
        if (type==TaskType.MAP)
            return true;
       
        return false;
    }
View Full Code Here

Examples of org.apache.hadoop.mapreduce.TaskType

      }
    }

    if (state == TaskStatus.State.SUCCEEDED) {
      assert grantId != null : "Grant for task id " + taskid + " is null!";
      TaskType taskType = tip.getAttemptType(taskid);
      if (taskType == TaskType.MAP || taskType == TaskType.REDUCE) {
        // Ignore cleanup tasks types.
        taskLookupTable.addSuccessfulTaskEntry(taskid, trackerName);
      }
      if (job.shouldReuseTaskResource(tip) || !assignedTip.equals(tip)) {
View Full Code Here

Examples of org.apache.hadoop.mapreduce.TaskType

   *          raw {@link TaskID} read from trace
   * @return masked {@link TaskID} with empty {@link JobID}.
   */
  private TaskID maskTaskID(TaskID taskId) {
    JobID jobId = new JobID();
    TaskType taskType = taskId.getTaskType();
    return new TaskID(jobId, taskType, taskId.getId());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.