Package eu.stratosphere.nephele.executiongraph

Examples of eu.stratosphere.nephele.executiongraph.ExecutionGraphIterator$TraversalEntry


    TaskCancelResult errorResult = null;

    /**
     * Cancel all nodes in the current and upper execution stages.
     */
    final Iterator<ExecutionVertex> it = new ExecutionGraphIterator(eg, eg.getIndexOfCurrentExecutionStage(),
      false, true);
    while (it.hasNext()) {

      final ExecutionVertex vertex = it.next();
      final TaskCancelResult result = vertex.cancelTask();
      if (result.getReturnCode() != AbstractTaskResult.ReturnCode.SUCCESS) {
        errorResult = result;
      }
    }
View Full Code Here


      return;
    }

    final Set<AbstractInstance> allocatedInstance = new HashSet<AbstractInstance>();

    final Iterator<ExecutionVertex> it = new ExecutionGraphIterator(eg, true);
    while (it.hasNext()) {

      final ExecutionVertex vertex = it.next();
      final ExecutionState state = vertex.getExecutionState();
      if (state == ExecutionState.RUNNING || state == ExecutionState.FINISHING) {
        final AbstractInstance instance = vertex.getAllocatedResource().getInstance();

        if (instance instanceof DummyInstance) {
View Full Code Here

   *        the submission time stamp of the job
   */
  public void registerJob(final ExecutionGraph executionGraph, final boolean profilingAvailable,
      final long submissionTimestamp) {

    final Iterator<ExecutionVertex> it = new ExecutionGraphIterator(executionGraph, true);

    while (it.hasNext()) {

      final ExecutionVertex vertex = it.next();

      // Register the listener object which will pass state changes on to the collector
      vertex.registerExecutionListener(new ExecutionListenerWrapper(this, vertex));

      // Register the listener object which will pass assignment changes on to the collector
View Full Code Here

   * @param eg
   *        the execution graph of the job to be unregistered
   */
  void unregisterJob(final ExecutionGraph eg) {

    final Iterator<ExecutionVertex> it = new ExecutionGraphIterator(eg, true);
    while (it.hasNext()) {
      this.splitMap.remove(it.next().getID());
    }
  }
View Full Code Here

    // Subscribe to job status notifications
    executionGraph.registerJobStatusListener(this);

    // Set state of each vertex for scheduled
    final ExecutionGraphIterator it2 = new ExecutionGraphIterator(executionGraph, true);
    while (it2.hasNext()) {

      final ExecutionVertex vertex = it2.next();
      vertex.registerExecutionListener(new LocalExecutionListener(this, vertex));
    }

    // Register the scheduler as an execution stage listener
    executionGraph.registerExecutionStageListener(this);
View Full Code Here

    // Subscribe to job status notifications
    executionGraph.registerJobStatusListener(this);

    // Register execution listener for each vertex
    final ExecutionGraphIterator it2 = new ExecutionGraphIterator(executionGraph, true);
    while (it2.hasNext()) {

      final ExecutionVertex vertex = it2.next();
      vertex.registerExecutionListener(new QueueExecutionListener(this, vertex));
    }

    // Register the scheduler as an execution stage listener
    executionGraph.registerExecutionStageListener(this);
View Full Code Here

      this.instanceManager.requestInstance(executionGraph.getJobID(), executionGraph.getJobConfiguration(),
        instanceRequestMap, null);

      // Switch vertex state to assigning
      final ExecutionGraphIterator it2 = new ExecutionGraphIterator(executionGraph, executionGraph
        .getIndexOfCurrentExecutionStage(), true, true);
      while (it2.hasNext()) {

        it2.next().compareAndUpdateExecutionState(ExecutionState.CREATED, ExecutionState.SCHEDULED);
      }
    }
  }
View Full Code Here

TOP

Related Classes of eu.stratosphere.nephele.executiongraph.ExecutionGraphIterator$TraversalEntry

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.