public virtual TaskAttemptsInfo GetJobTaskAttempts(HttpServletRequest hsr, string jid, string tid) { Init(); TaskAttemptsInfo attempts = new TaskAttemptsInfo(); Org.Apache.Hadoop.Mapreduce.V2.App.Job.Job job = AMWebServices.GetJobFromJobIdString (jid, ctx); CheckAccess(job, hsr); Task task = AMWebServices.GetTaskFromTaskIdString(tid, job); foreach (TaskAttempt ta in task.GetAttempts().Values) { if (ta != null) { if (task.GetType() == TaskType.Reduce) { attempts.Add(new ReduceTaskAttemptInfo(ta, task.GetType())); } else { attempts.Add(new TaskAttemptInfo(ta, task.GetType(), false)); } } } return(attempts); }
public virtual TaskInfo GetJobTask(HttpServletRequest hsr, string jid, string tid ) { Init(); Org.Apache.Hadoop.Mapreduce.V2.App.Job.Job job = AMWebServices.GetJobFromJobIdString (jid, ctx); CheckAccess(job, hsr); Task task = AMWebServices.GetTaskFromTaskIdString(tid, job); return(new TaskInfo(task)); }
public virtual JobTaskAttemptCounterInfo GetJobTaskAttemptIdCounters(HttpServletRequest hsr, string jid, string tid, string attId) { Init(); Org.Apache.Hadoop.Mapreduce.V2.App.Job.Job job = AMWebServices.GetJobFromJobIdString (jid, ctx); CheckAccess(job, hsr); Task task = AMWebServices.GetTaskFromTaskIdString(tid, job); TaskAttempt ta = AMWebServices.GetTaskAttemptFromTaskAttemptString(attId, task); return(new JobTaskAttemptCounterInfo(ta)); }
public virtual TaskAttemptInfo GetJobTaskAttemptId(HttpServletRequest hsr, string jid, string tid, string attId) { Init(); Org.Apache.Hadoop.Mapreduce.V2.App.Job.Job job = AMWebServices.GetJobFromJobIdString (jid, ctx); CheckAccess(job, hsr); Task task = AMWebServices.GetTaskFromTaskIdString(tid, job); TaskAttempt ta = AMWebServices.GetTaskAttemptFromTaskAttemptString(attId, task); if (task.GetType() == TaskType.Reduce) { return(new ReduceTaskAttemptInfo(ta, task.GetType())); } else { return(new TaskAttemptInfo(ta, task.GetType(), false)); } }