Package org.apache.pig.experimental.plan

Examples of org.apache.pig.experimental.plan.ReverseDependencyOrderWalker


       
        plan.connect(fred, joe);
        plan.connect(joe, bob);
       
        SillyVisitor v =
            new SillyVisitor(plan, new ReverseDependencyOrderWalker(plan));
       
        v.visit();
       
        String s = v.getVisitPattern();
       
View Full Code Here


        plan.connect(joe, bob);
        plan.connect(bob, jill);
        plan.connect(jane, jill);
       
        SillyVisitor v =
            new SillyVisitor(plan, new ReverseDependencyOrderWalker(plan));
       
        v.visit();
       
        String s = v.getVisitPattern();
       
View Full Code Here

        plan.connect(joe, bob);
        plan.connect(bob, jill);
        plan.connect(bob, jane);
       
        SillyVisitor v =
            new SillyVisitor(plan, new ReverseDependencyOrderWalker(plan));
       
        v.visit();
       
        String s = v.getVisitPattern();
       
View Full Code Here

   
       
        // visitor to change the plan to remove unnecessary columns
        private class ColumnPruneVisitor extends LogicalPlanVisitor {
            public ColumnPruneVisitor(OperatorPlan plan) {
                super(plan, new ReverseDependencyOrderWalker(plan));                       
            }
View Full Code Here

    static public class MapMarker extends AllExpressionVisitor {
       
        Map<Long,Set<String>> inputUids = null;

        protected MapMarker(OperatorPlan plan) {
            super(plan, new ReverseDependencyOrderWalker(plan));
            inputUids = new HashMap<Long,Set<String>>();
        }
View Full Code Here

            }
        }
    }
   
    public PlanPrinter(OperatorPlan plan, PrintStream ps) {
        super(plan, new ReverseDependencyOrderWalker(plan));
        stream = ps;
    }
View Full Code Here

        currentPlan = new PhysicalPlan();

//        PlanWalker childWalker = currentWalker
//                .spawnChildWalker(filter.getFilterPlan());
        PlanWalker childWalker = new ReverseDependencyOrderWalker(filter.getFilterPlan());
        pushWalker(childWalker);
        //currentWalker.walk(this);
        currentWalker.walk(
                new ExpToPhyTranslationVisitor( currentWalker.getPlan(),
                        childWalker, filter, currentPlan, logToPhyMap ) );
View Full Code Here

        // The physical plan should contain the expression plan for this predecessor plus
        // the subtree starting with this predecessor
        for (int i=0; i<exps.size(); i++) {
            currentPlan = new PhysicalPlan();
            // translate the expression plan
            PlanWalker childWalker = new ReverseDependencyOrderWalker(exps.get(i));
            pushWalker(childWalker);
            childWalker.walk(new ExpToPhyTranslationVisitor(exps.get(i),
                    childWalker, gen, currentPlan, logToPhyMap ));           
            popWalker();
           
            List<Operator> leaves = exps.get(i).getSinks();
            for(Operator l: leaves) {
                PhysicalOperator op = logToPhyMap.get(l);
                if (l instanceof ProjectExpression ) {
                    int input = ((ProjectExpression)l).getInputNum();                   
                   
                    // for each sink projection, get its input logical plan and translate it
                    Operator pred = preds.get(input);
                    childWalker = new SubtreeDependencyOrderWalker(inner, pred);
                    pushWalker(childWalker);
                    childWalker.walk(this);
                    popWalker();
                   
                    // get the physical operator of the leaf of input logical plan
                    PhysicalOperator leaf = logToPhyMap.get(pred);                   
                   
View Full Code Here

    // a schema. They may be the uids of lower level fields of complex fields
    // that have their own schema.
    private class ColumnDependencyVisitor extends LogicalPlanVisitor {     
       
        public ColumnDependencyVisitor(OperatorPlan plan) {
            super(plan, new ReverseDependencyOrderWalker(plan));           
        }
View Full Code Here

        for( LogicalExpressionPlan lp : plans ) {
            currentPlan = new PhysicalPlan();
           
            // We spawn a new Dependency Walker and use it
            // PlanWalker childWalker = currentWalker.spawnChildWalker(lp);
            PlanWalker childWalker = new ReverseDependencyOrderWalker(lp);
           
            // Save the old walker and use childWalker as current Walker
            pushWalker(childWalker);
           
            // We create a new ExpToPhyTranslationVisitor to walk the ExpressionPlan
View Full Code Here

TOP

Related Classes of org.apache.pig.experimental.plan.ReverseDependencyOrderWalker

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.