Package org.apache.hadoop.mapred

Examples of org.apache.hadoop.mapred.JobProfile


   */
  public void generateJobTable(JspWriter out, String label, List<JobInProgress> jobs)
      throws IOException {
    if (jobs.size() > 0) {
      for (JobInProgress job : jobs) {
        JobProfile profile = job.getProfile();
        JobStatus status = job.getStatus();
        JobID jobid = profile.getJobID();

        int desiredMaps = job.desiredMaps();
        int desiredReduces = job.desiredReduces();
        int completedMaps = job.finishedMaps();
        int completedReduces = job.finishedReduces();
        String name = profile.getJobName();

        out.print("<" + label + "_job jobid=\"" + jobid + "\">\n");
        out.print("  <jobid>" + jobid + "</jobid>\n");
        out.print("  <user>" + profile.getUser() + "</user>\n");
        out.print("  <name>" + ("".equals(name) ? "&nbsp;" : name) + "</name>\n");
        out.print("  <map_complete>" + StringUtils.formatPercent(status.mapProgress(), 2) + "</map_complete>\n");
        out.print("  <map_total>" + desiredMaps + "</map_total>\n");
        out.print("  <maps_completed>" + completedMaps + "</maps_completed>\n");
        out.print("  <reduce_complete>" + StringUtils.formatPercent(status.reduceProgress(), 2) + "</reduce_complete>\n");
View Full Code Here


    JobID bestid = jobid;
    if (childid != null)
      bestid = StatusDelegator.StringToJobID(childid);

    JobStatus status = tracker.getJobStatus(bestid);
    JobProfile profile = tracker.getJobProfile(bestid);

    if (status == null || profile == null) {
      if (bestid != jobid) { // Corrupt childid, retry.
        LOG.error("Corrupt child id " + childid + " for " + jobid);
        bestid = jobid;
View Full Code Here

        JobID bestid = jobid;
        if (childid != null)
            bestid = StatusDelegator.StringToJobID(childid);

        JobStatus status = tracker.getJobStatus(bestid);
        JobProfile profile = tracker.getJobProfile(bestid);

        if (status == null || profile == null) {
            if (bestid != jobid) { // Corrupt childid, retry.
                LOG.error("Corrupt child id " + childid + " for " + jobid);
                bestid = jobid;
View Full Code Here

                       JobID jobid,
                       JobState state)
    throws BadParam, IOException {

    JobStatus status = tracker.getJobStatus(jobid);
    JobProfile profile = tracker.getJobProfile(jobid);
    if (status == null || profile == null) // No such job.
      throw new BadParam("Could not find job " + jobid);

    return new QueueStatusBean(state, status, profile);
  }
View Full Code Here

   */
  public void generateJobTable(JspWriter out, String label, List<JobInProgress> jobs)
      throws IOException {
    if (jobs.size() > 0) {
      for (JobInProgress job : jobs) {
        JobProfile profile = job.getProfile();
        JobStatus status = job.getStatus();
        JobID jobid = profile.getJobID();

        int desiredMaps = job.desiredMaps();
        int desiredReduces = job.desiredReduces();
        int completedMaps = job.finishedMaps();
        int completedReduces = job.finishedReduces();
        String name = profile.getJobName();

        out.print("<" + label + "_job jobid=\"" + jobid + "\">\n");
        out.print("  <jobid>" + jobid + "</jobid>\n");
        out.print("  <user>" + profile.getUser() + "</user>\n");
        out.print("  <name>" + ("".equals(name) ? "&nbsp;" : name) + "</name>\n");
        out.print("  <map_complete>" + StringUtils.formatPercent(status.mapProgress(), 2) + "</map_complete>\n");
        out.print("  <map_total>" + desiredMaps + "</map_total>\n");
        out.print("  <maps_completed>" + completedMaps + "</maps_completed>\n");
        out.print("  <reduce_complete>" + StringUtils.formatPercent(status.reduceProgress(), 2) + "</reduce_complete>\n");
View Full Code Here

        JobID bestid = jobid;
        if (childid != null)
            bestid = StatusDelegator.StringToJobID(childid);

        JobStatus status = tracker.getJobStatus(bestid);
        JobProfile profile = tracker.getJobProfile(bestid);

        if (status == null || profile == null) {
            if (bestid != jobid) { // Corrupt childid, retry.
                LOG.error("Corrupt child id " + childid + " for " + jobid);
                bestid = jobid;
View Full Code Here

   */
  public void generateJobTable(JspWriter out, String label, List<JobInProgress> jobs)
      throws IOException {
    if (jobs.size() > 0) {
      for (JobInProgress job : jobs) {
        JobProfile profile = job.getProfile();
        JobStatus status = job.getStatus();
        JobID jobid = profile.getJobID();

        int desiredMaps = job.desiredMaps();
        int desiredReduces = job.desiredReduces();
        int completedMaps = job.finishedMaps();
        int completedReduces = job.finishedReduces();
        String name = profile.getJobName();

        out.print("<" + label + "_job jobid=\"" + jobid + "\">\n");
        out.print("  <jobid>" + jobid + "</jobid>\n");
        out.print("  <user>" + profile.getUser() + "</user>\n");
        out.print("  <name>" + ("".equals(name) ? "&nbsp;" : name) + "</name>\n");
        out.print("  <map_complete>" + StringUtils.formatPercent(status.mapProgress(), 2) + "</map_complete>\n");
        out.print("  <map_total>" + desiredMaps + "</map_total>\n");
        out.print("  <maps_completed>" + completedMaps + "</maps_completed>\n");
        out.print("  <reduce_complete>" + StringUtils.formatPercent(status.reduceProgress(), 2) + "</reduce_complete>\n");
View Full Code Here

TOP

Related Classes of org.apache.hadoop.mapred.JobProfile

Copyright © 2018 www.massapicom. 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.