public ConsecutiveTapsPartitionExpression() { super( new NoGroupTapExpressionGraph(), new ConsecutiveTapsExpressionGraph() ); } }
public ConsecutiveTapsPartitionExpression() { super( new NoGroupTapExpressionGraph(), new ConsecutiveTapsExpressionGraph() ); } }
public TapGroupTapPartitionExpression() { super( new NoGroupTapExpressionGraph(), new TapGroupTapExpressionGraph() ); } }
public GroupTapPartitionExpression() { super( new NoGroupTapExpressionGraph(), new GroupTapExpressionGraph() ); } }
public GroupTapPartitionExpression() { super( new NoGroupTapExpressionGraph(), new GroupTapExpressionGraph() ); } }
public TapGroupTapPartitionExpression() { super( new NoGroupTapExpressionGraph(), new TapGroupTapExpressionGraph() ); } }
public MultiTapGroupNodePartitioner() { super( PartitionNodes, new RuleExpression( new NoGroupTapExpressionGraph(), new MultiTapGroupExpressionGraph() ) ); } }
public MultiTapGroupNodePartitioner() { super( PartitionNodes, new RuleExpression( new NoGroupTapExpressionGraph(), new MultiTapGroupExpressionGraph() ) ); } }
@Test public void testFindAllMatched() { // ElementGraph graph = new HashJoinSameSourceGraph(); ElementGraph graph = new JoinAroundJoinRightMostGraph(); graph.writeDOT( getPlanPath() + "/full.dot" ); // graph = new ContractedTransform( new SyncPipeExpressionGraph() ).transform( graph ).getEndGraph(); graph = new ContractedTransformer( new NoGroupTapExpressionGraph() ).transform( graph ).getEndGraph(); graph.writeDOT( getPlanPath() + "/contracted.dot" ); ExpressionGraph expressionGraph = new ExpressionGraph( new FlowElementExpression( ElementCapture.Primary, Tap.class ) ); GraphFinder graphFinder = new GraphFinder( expressionGraph ); Match match = graphFinder.findAllMatches( graph ); match.getMatchedGraph().writeDOT( getPlanPath() + "/match.dot" ); } }
@Test public void testFindAllOnPrimary() { // ElementGraph graph = new HashJoinSameSourceGraph(); ElementGraph graph = new JoinAroundJoinRightMostGraph(); graph.writeDOT( getPlanPath() + "/full.dot" ); // graph = new ContractedTransform( new SyncPipeExpressionGraph() ).transform( graph ).getEndGraph(); graph = new ContractedTransformer( new NoGroupTapExpressionGraph() ).transform( graph ).getEndGraph(); graph.writeDOT( getPlanPath() + "/contracted.dot" ); ExpressionGraph expressionGraph = new ExpressionGraph() .arc( new FlowElementExpression( Tap.class ), ScopeExpression.ALL, new FlowElementExpression( ElementCapture.Primary, HashJoin.class ) ); GraphFinder graphFinder = new GraphFinder( expressionGraph ); Match match = graphFinder.findAllMatchesOnPrimary( graph ); match.getMatchedGraph().writeDOT( getPlanPath() + "/match.dot" ); }
@Test public void testSubGraphIterator() { RuleRegistry ruleRegistry = new RuleRegistry(); ruleRegistry.addElementFactory( NonTapFactory.TEMP_TAP, new NonTapFactory() ); PlannerContext plannerContext = new PlannerContext( ruleRegistry, null, null, null, true ); ruleRegistry.addRule( new RuleInsertionTransformer( PlanPhase.PreResolveAssembly, new TestCheckpointExpression(), IntermediateTapElementFactory.TEMP_TAP ) ); // ruleRegistry.addRule( new RuleContractedTransform( PlanPhase.PreResolve, new NoOpPipeExpression() ) ); RuleResult ruleResult = new RuleExec( new TraceWriter(), ruleRegistry ).executeRulePhase( PlanPhase.PreResolveAssembly, plannerContext, new RuleResult( new StandardElementGraph() ) ); FlowElementGraph flowElementGraph = ruleResult.getAssemblyGraph(); SubGraphIterator iterator = new ExpressionSubGraphIterator( new PlannerContext(), new NoGroupTapExpressionGraph(), new TapGroupTapExpressionGraph(), flowElementGraph ); while( iterator.hasNext() ) assertNotNull( iterator.next() ); }