String newHCatDependency3 = "hcat://" + server + "/" + db + "/" + table + "/dt=20120430;country=russia";
CoordinatorActionBean action2 = addRecordToCoordActionTableForWaiting(job.getId(), 2,
CoordinatorAction.Status.WAITING, "coord-action-for-action-input-check.xml", null,
newHCatDependency3, "Z");
HCatURI hcatURI1, hcatURI2, hcatURI3;
hcatURI1 = new HCatURI(newHCatDependency1);
hcatURI2 = new HCatURI(newHCatDependency2);
hcatURI3 = new HCatURI(newHCatDependency3);
pdms.addMissingDependency(hcatURI1, action1.getId());
pdms.addMissingDependency(hcatURI2, action1.getId());
pdms.addMissingDependency(hcatURI3, action2.getId());
assertTrue(pdms.getWaitingActions(new HCatURI(newHCatDependency1)).contains(action1.getId()));
assertTrue(pdms.getWaitingActions(new HCatURI(newHCatDependency2)).contains(action1.getId()));
assertTrue(pdms.getWaitingActions(new HCatURI(newHCatDependency3)).contains(action2.getId()));
new CoordKillXCommand(job.getId()).call();
assertNull(pdms.getWaitingActions(new HCatURI(newHCatDependency1)));
assertNull(pdms.getWaitingActions(new HCatURI(newHCatDependency2)));
assertNull(pdms.getWaitingActions(new HCatURI(newHCatDependency3)));
}
catch (Exception e) {
e.printStackTrace();
fail(e.getMessage());
}