Package org.apache.flink.compiler.plan

Examples of org.apache.flink.compiler.plan.OptimizedPlan


     
      @Override
      public void postVisit(Operator<?> visitable) {}
    });
   
    OptimizedPlan op = compileWithStats(plan);
   
    return (DualInputPlanNode) ((SinkPlanNode) op.getDataSinks().iterator().next()).getInput().getSource();
  }
View Full Code Here


    sink.setInput(reduce2);
   
    Plan plan = new Plan(sink, "Test Increasing Degree Of Parallelism");
   
    // submit the plan to the compiler
    OptimizedPlan oPlan = compileNoStats(plan);
   
    // check the optimized Plan
    // when reducer 1 distributes its data across the instances of map2, it needs to employ a local hash method,
    // because map2 has twice as many instances and key/value pairs with the same key need to be processed by the same
    // mapper respectively reducer
    SinkPlanNode sinkNode = oPlan.getDataSinks().iterator().next();
    SingleInputPlanNode red2Node = (SingleInputPlanNode) sinkNode.getPredecessor();
   
    Assert.assertEquals("The Reduce 2 Node has an invalid local strategy.", LocalStrategy.SORT, red2Node.getInput().getLocalStrategy());
  }
View Full Code Here

   
   
    // return the PACT plan
    Plan plan = new Plan(sink, "Partition on DoP Change");
   
    OptimizedPlan oPlan = compileNoStats(plan);
   
    NepheleJobGraphGenerator jobGen = new NepheleJobGraphGenerator();
   
    //Compile plan to verify that no error is thrown
    jobGen.compileJobGraph(oPlan);
   
    oPlan.accept(new Visitor<PlanNode>() {
     
      @Override
      public boolean preVisit(PlanNode visitable) {
        if (visitable instanceof DualInputPlanNode) {
          DualInputPlanNode node = (DualInputPlanNode) visitable;
View Full Code Here

        }
      }).name("reducer")
      .print().name("sink");
     
      Plan p = env.createProgramPlan();
      OptimizedPlan op = compileNoStats(p);
     
      OptimizerPlanNodeResolver resolver = getOptimizerPlanNodeResolver(op);
     
     
      // the all-reduce has no combiner, when the DOP of the input is one
View Full Code Here

        }
      }).name("reducer")
      .print().name("sink");
     
      Plan p = env.createProgramPlan();
      OptimizedPlan op = compileNoStats(p);
     
      OptimizerPlanNodeResolver resolver = getOptimizerPlanNodeResolver(op);
     
      // get the original nodes
      SourcePlanNode sourceNode = resolver.getNode("source");
View Full Code Here

        }
      }).name("reducer")
      .print().name("sink");
     
      Plan p = env.createProgramPlan();
      OptimizedPlan op = compileNoStats(p);
     
      OptimizerPlanNodeResolver resolver = getOptimizerPlanNodeResolver(op);
     
      // get the original nodes
      SourcePlanNode sourceNode = resolver.getNode("source");
View Full Code Here

        }
      }).name("reducer")
      .print().name("sink");
     
      Plan p = env.createProgramPlan();
      OptimizedPlan op = compileNoStats(p);
     
      OptimizerPlanNodeResolver resolver = getOptimizerPlanNodeResolver(op);
     
      // get the original nodes
      SourcePlanNode sourceNode = resolver.getNode("source");
View Full Code Here

    union.print();
    union.print();

    Plan plan = env.createProgramPlan();
    try{
      OptimizedPlan oPlan = this.compileNoStats(plan);
      NepheleJobGraphGenerator jobGen = new NepheleJobGraphGenerator();
      jobGen.compileJobGraph(oPlan);
    }catch(CompilerException co){
      co.printStackTrace();
      fail("The Pact compiler is unable to compile this plan correctly.");
View Full Code Here

    sink.setInput(reduce3);
   
    Plan plan = new Plan(sink, "Test Temp Task");
    plan.setDefaultParallelism(DEFAULT_PARALLELISM);
   
    OptimizedPlan oPlan = compileNoStats(plan);
    NepheleJobGraphGenerator jobGen = new NepheleJobGraphGenerator();
    jobGen.compileJobGraph(oPlan);
  }
View Full Code Here

        public void reduce(Iterable<Double> values, Collector<Double> out) {}
      }).name("reducer")
      .print().name("sink");
     
      Plan p = env.createProgramPlan();
      OptimizedPlan op = compileNoStats(p);
     
      OptimizerPlanNodeResolver resolver = getOptimizerPlanNodeResolver(op);
     
     
      // the all-reduce has no combiner, when the DOP of the input is one
View Full Code Here

TOP

Related Classes of org.apache.flink.compiler.plan.OptimizedPlan

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.