new ContractITCaseInputFormat(), rightInPath);
DelimitedInputFormat.configureDelimitedFormat(input_right)
.recordDelimiter('\n');
input_right.setDegreeOfParallelism(config.getInteger("MatchTest#NoSubtasks", 1));
JoinOperator testMatcher = JoinOperator.builder(new TestMatcher(), StringValue.class, 0, 0)
.build();
testMatcher.setDegreeOfParallelism(config.getInteger("MatchTest#NoSubtasks", 1));
testMatcher.getParameters().setString(PactCompiler.HINT_LOCAL_STRATEGY,
config.getString("MatchTest#LocalStrategy", ""));
if (config.getString("MatchTest#ShipStrategy", "").equals("BROADCAST_FIRST")) {
testMatcher.getParameters().setString(PactCompiler.HINT_SHIP_STRATEGY_FIRST_INPUT,
PactCompiler.HINT_SHIP_STRATEGY_BROADCAST);
testMatcher.getParameters().setString(PactCompiler.HINT_SHIP_STRATEGY_SECOND_INPUT,
PactCompiler.HINT_SHIP_STRATEGY_FORWARD);
} else if (config.getString("MatchTest#ShipStrategy", "").equals("BROADCAST_SECOND")) {
testMatcher.getParameters().setString(PactCompiler.HINT_SHIP_STRATEGY_FIRST_INPUT,
PactCompiler.HINT_SHIP_STRATEGY_FORWARD);
testMatcher.getParameters().setString(PactCompiler.HINT_SHIP_STRATEGY_SECOND_INPUT,
PactCompiler.HINT_SHIP_STRATEGY_BROADCAST);
} else {
testMatcher.getParameters().setString(PactCompiler.HINT_SHIP_STRATEGY,
config.getString("MatchTest#ShipStrategy", ""));
}
FileDataSink output = new FileDataSink(
new ContractITCaseOutputFormat(), resultPath);
output.setDegreeOfParallelism(1);
output.setInput(testMatcher);
testMatcher.setFirstInput(input_left);
testMatcher.setSecondInput(input_right);
return new Plan(output);
}