NemoBackend implements Backend<PhysicalPlan> { public PhysicalPlan compile(final IRDAG irDAG) { final DAG<Stage, StageEdge> stageDAG = physicalPlanGenerator.apply(irDAG); return new PhysicalPlan(RuntimeIdManager.generatePhysicalPlanId(), stageDAG); } @Inject private  NemoBackend(final PhysicalPlanGenerator physicalPlanGenerator); PhysicalPlan compile(final IRDAG irDAG);  }
@Test public void testExecutionPlanGeneration() { final PhysicalPlan executionPlan = nemoBackend.compile(dag); assertEquals(2, executionPlan.getStageDAG().getVertices().size()); assertEquals(2, executionPlan.getStageDAG().getTopologicalSort().get(0).getIRDAG().getVertices().size()); assertEquals(3, executionPlan.getStageDAG().getTopologicalSort().get(1).getIRDAG().getVertices().size()); }