Package eu.stratosphere.api.common

Examples of eu.stratosphere.api.common.Plan


        public Tuple3<Double, StringValue, LongValue> reduce(Tuple3<Double, StringValue, LongValue> value1, Tuple3<Double, StringValue, LongValue> value2) {
          return value1;
        }
      }).print();
     
      Plan p = env.createProgramPlan();
     
      GenericDataSinkBase<?> sink = p.getDataSinks().iterator().next();
     
      ReduceOperatorBase<?, ?> reducer = (ReduceOperatorBase<?, ?>) sink.getInput();
     
      // check types
      assertEquals(initialData.getType(), reducer.getOperatorInfo().getInputType());
View Full Code Here


            return value1;
          }
        })
        .print();
     
      Plan p = env.createProgramPlan();
     
      GenericDataSinkBase<?> sink = p.getDataSinks().iterator().next();
     
      ReduceOperatorBase<?, ?> reducer = (ReduceOperatorBase<?, ?>) sink.getInput();
     
      // check types
      assertEquals(initialData.getType(), reducer.getOperatorInfo().getInputType());
View Full Code Here

        DataSet<Tuple2<Long, Long>> result = initialVertices.runOperation(VertexCentricIteration.withPlainEdges(edges, new CCUpdater(), new CCMessager(), 100));
       
        result.print();
      }
     
      Plan p = env.createProgramPlan("Spargel Connected Components");
      OptimizedPlan op = compileNoStats(p);
     
      // check the sink
      SinkPlanNode sink = op.getDataSinks().iterator().next();
      assertEquals(ShipStrategyType.FORWARD, sink.getInput().getShipStrategy());
View Full Code Here

            return value1;
          }
        }).setParallelism(4)
        .print();
     
      Plan p = env.createProgramPlan();
     
      GenericDataSinkBase<?> sink = p.getDataSinks().iterator().next();
     
     
      MapOperatorBase<?, ?, ?> keyProjector = (MapOperatorBase<?, ?, ?>) sink.getInput();
      PlanUnwrappingReduceOperator<?, ?> reducer = (PlanUnwrappingReduceOperator<?, ?>) keyProjector.getInput();
      MapOperatorBase<?, ?, ?> keyExtractor = (MapOperatorBase<?, ?, ?>) reducer.getInput();
View Full Code Here

        DataSet<Tuple2<Long, Long>> result = initialVertices.runOperation(vcIter);
       
        result.print();
      }
     
      Plan p = env.createProgramPlan("Spargel Connected Components");
      OptimizedPlan op = compileNoStats(p);
     
      // check the sink
      SinkPlanNode sink = op.getDataSinks().iterator().next();
      assertEquals(ShipStrategyType.FORWARD, sink.getInput().getShipStrategy());
View Full Code Here

      .recordDelimiter('\n')
      .fieldDelimiter(' ')
      .field(StringValue.class, 0)
      .field(IntValue.class, 1);
   
    Plan plan = new Plan(out, "WordCount Example");
    plan.setDefaultParallelism(numSubTasks);
    return plan;
  }
View Full Code Here

    if (args.length < 3) {
      System.err.println(wc.getDescription());
      System.exit(1);
    }
   
    Plan plan = wc.getPlan(args);
   
    // This will execute the word-count embedded in a local context. replace this line by the commented
    // succeeding line to send the job to a local installation or to a cluster for execution
    LocalExecutor.execute(plan);
//    PlanExecutor ex = new RemoteExecutor("localhost", 6123, "target/pact-examples-0.4-SNAPSHOT-WordCount.jar");
View Full Code Here

      DataSet<Tuple3<Double, StringValue, Long>> initialData =
          env.fromElements(new Tuple3<Double, StringValue, Long>(3.141592, new StringValue("foobar"), new Long(77)));
     
      initialData.groupBy(0).aggregate(Aggregations.MIN, 1).and(Aggregations.SUM, 2).print();
     
      Plan p = env.createProgramPlan();
     
      GenericDataSinkBase<?> sink = p.getDataSinks().iterator().next();
     
      GroupReduceOperatorBase<?, ?, ?> reducer = (GroupReduceOperatorBase<?, ?, ?>) sink.getInput();
     
      // check keys
      assertEquals(1, reducer.getKeyColumns(0).length);
View Full Code Here

      .field(StringValue.class, 0)
      .field(StringValue.class, 1)
      .field(StringValue.class, 2)
      .field(StringValue.class, 3);
   
    Plan plan = new Plan(out, "HBase access Example");
    plan.setDefaultParallelism(numSubTasks);
    return plan;
  }
View Full Code Here

public class ConnectedComponentsITCase extends eu.stratosphere.test.iterative.ConnectedComponentsITCase {

  @Override
  protected Plan getTestJob() {
    ConnectedComponents cc = new ConnectedComponents();
    Plan plan = cc.getScalaPlan(verticesPath, edgesPath, resultPath, 100);
    plan.setDefaultParallelism(4);
    return plan;
  }
View Full Code Here

TOP

Related Classes of eu.stratosphere.api.common.Plan

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.