Package eu.stratosphere.nephele.client

Examples of eu.stratosphere.nephele.client.JobProgressResult


  @Override
  public JobProgressResult getJobProgress(final JobID jobID) throws IOException {

    if (this.eventCollector == null) {
      return new JobProgressResult(ReturnCode.ERROR, "JobManager does not support progress reports for jobs",
        null);
    }

    final SerializableArrayList<AbstractEvent> eventList = new SerializableArrayList<AbstractEvent>();
    this.eventCollector.getEventsForJob(jobID, eventList, false);

    return new JobProgressResult(ReturnCode.SUCCESS, null, eventList);
  }
View Full Code Here


            throw new IllegalStateException("Cancelling of job took " + (now - cancelTime)
              + " milliseconds, only " + maxTimeTillCanceled + " milliseconds are allowed");
          }
        }

        final JobProgressResult jobProgressResult = client.getJobProgress();

        if (jobProgressResult == null) {
          throw new IllegalStateException("Returned job progress is unexpectedly null!");
        }

        if (jobProgressResult.getReturnCode() == AbstractJobResult.ReturnCode.ERROR) {
          throw new IllegalStateException("Could not retrieve job progress: "
            + jobProgressResult.getDescription());
        }

        boolean exitLoop = false;

        final Iterator<AbstractEvent> it = jobProgressResult.getEvents();
        while (it.hasNext()) {

          final AbstractEvent event = it.next();

          // Did we already process that event?
View Full Code Here

TOP

Related Classes of eu.stratosphere.nephele.client.JobProgressResult

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.