// construct the plan
FileDataSource sourceA = new FileDataSource(new DummyInputFormat(), IN_FILE);
FileDataSource sourceB = new FileDataSource(new DummyInputFormat(), IN_FILE);
ReduceOperator redA = ReduceOperator.builder(new IdentityReduce(), IntValue.class, 0)
.input(sourceA)
.build();
ReduceOperator redB = ReduceOperator.builder(new IdentityReduce(), IntValue.class, 0)
.input(sourceB)
.build();
JoinOperator mat = JoinOperator.builder(new DummyMatchStub(), IntValue.class, 0, 0)
.input1(redA)
.input2(redB)
.build();
FileDataSink sink = new FileDataSink(new DummyOutputFormat(), OUT_FILE, mat);
sourceA.setDegreeOfParallelism(5);
sourceB.setDegreeOfParallelism(7);
redA.setDegreeOfParallelism(5);
redB.setDegreeOfParallelism(7);
mat.setDegreeOfParallelism(5);
sink.setDegreeOfParallelism(5);