* @throws NotFoundException
* @throws CannotCompileException
*/
public boolean run(int nparts, String[] inputs, String output)
throws NotFoundException, CannotCompileException {
EdgeIngressMR job1 = new EdgeIngressMR(
graphParserClass(),
ParserFactory
.getParserByClassName(vidClass().getName()).getClass(),
ParserFactory
.getParserByClassName(vdataClass().getName()).getClass(),
ParserFactory
.getParserByClassName(edataClass().getName()).getClass());
job1.setKeyValueClass(IngressJobKeyValueFactory
.getKeyClassByClassName(vidClass().getName()),
IngressJobKeyValueFactory.getValueClassByClassName(
vidClass().getName(), vdataClass().getName(), edataClass()
.getName()));
// Distribute new class file to cluster.
FsUtil.distributedTempClassToClassPath(job1.getConf());
VrecordIngressMR job2 = new VrecordIngressMR();
try {
job1.run(inputs, output + "/edges", nparts, "greedy");
job2.run(nparts, output + "/edges/vrecord", output + "/vrecords");
} catch (Exception e) {
e.printStackTrace();
return false;
}