Program: 56215
Project: 56215
Buggy source:
/** 
 * Assembles the Plan of the triangle enumeration example Pact program.
 */
@Override public Plan getPlan(String... args){
  if (args.length != 3) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  int noSubTasks=Integer.parseInt(args[0]);
  String edgeInput=args[1];
  String output=args[2];
  DataSourceContract<Edge,PactNull> edges=new DataSourceContract<Edge,PactNull>(EdgeListInFormat.class,edgeInput);
  edges.setFormatParameter("String_Node_Str","String_Node_Str");
  edges.setDegreeOfParallelism(noSubTasks);
  edges.setOutputContract(UniqueKey.class);
  MapContract<Edge,PactNull,PactString,Edge> assignKeys=new MapContract<Edge,PactNull,PactString,Edge>(AssignKeys.class,"String_Node_Str");
  assignKeys.setDegreeOfParallelism(noSubTasks);
  ReduceContract<PactString,Edge,Edge,EdgeList> buildTriads=new ReduceContract<PactString,Edge,Edge,EdgeList>(BuildTriads.class,"String_Node_Str");
  buildTriads.setDegreeOfParallelism(noSubTasks);
  MatchContract<Edge,EdgeList,PactNull,PactNull,EdgeList> closeTriads=new MatchContract<Edge,EdgeList,PactNull,PactNull,EdgeList>(CloseTriads.class,"String_Node_Str");
  closeTriads.setDegreeOfParallelism(noSubTasks);
  closeTriads.getStubParameters().setString(PactCompiler.HINT_LOCAL_STRATEGY,PactCompiler.HINT_LOCAL_STRATEGY_SORT);
  DataSinkContract<PactNull,EdgeList> triangles=new DataSinkContract<PactNull,EdgeList>(EdgeListOutFormat.class,output);
  triangles.setDegreeOfParallelism(noSubTasks);
  triangles.setInput(closeTriads);
  closeTriads.setSecondInput(edges);
  closeTriads.setFirstInput(buildTriads);
  buildTriads.setInput(assignKeys);
  assignKeys.setInput(edges);
  return new Plan(triangles,"String_Node_Str");
}

Fixed version (ground truth):
/** 
 * Assembles the Plan of the triangle enumeration example Pact program.
 */
@Override public Plan getPlan(String... args){
  int noSubTasks=(args.length > 0 ? Integer.parseInt(args[0]) : 1);
  String edgeInput=(args.length > 1 ? args[1] : "String_Node_Str");
  String output=(args.length > 2 ? args[2] : "String_Node_Str");
  DataSourceContract<Edge,PactNull> edges=new DataSourceContract<Edge,PactNull>(EdgeListInFormat.class,edgeInput);
  edges.setFormatParameter("String_Node_Str","String_Node_Str");
  edges.setDegreeOfParallelism(noSubTasks);
  edges.setOutputContract(UniqueKey.class);
  MapContract<Edge,PactNull,PactString,Edge> assignKeys=new MapContract<Edge,PactNull,PactString,Edge>(AssignKeys.class,"String_Node_Str");
  assignKeys.setDegreeOfParallelism(noSubTasks);
  ReduceContract<PactString,Edge,Edge,EdgeList> buildTriads=new ReduceContract<PactString,Edge,Edge,EdgeList>(BuildTriads.class,"String_Node_Str");
  buildTriads.setDegreeOfParallelism(noSubTasks);
  MatchContract<Edge,EdgeList,PactNull,PactNull,EdgeList> closeTriads=new MatchContract<Edge,EdgeList,PactNull,PactNull,EdgeList>(CloseTriads.class,"String_Node_Str");
  closeTriads.setDegreeOfParallelism(noSubTasks);
  closeTriads.getStubParameters().setString(PactCompiler.HINT_LOCAL_STRATEGY,PactCompiler.HINT_LOCAL_STRATEGY_SORT);
  DataSinkContract<PactNull,EdgeList> triangles=new DataSinkContract<PactNull,EdgeList>(EdgeListOutFormat.class,output);
  triangles.setDegreeOfParallelism(noSubTasks);
  triangles.setInput(closeTriads);
  closeTriads.setSecondInput(edges);
  closeTriads.setFirstInput(buildTriads);
  buildTriads.setInput(assignKeys);
  assignKeys.setInput(edges);
  return new Plan(triangles,"String_Node_Str");
}