use of org.apache.flink.runtime.jobmanager.scheduler.CoLocationConstraint in project flink by apache.
the class ExecutionGraphRestartTest method validateConstraints.
private void validateConstraints(ExecutionGraph eg) {
ExecutionJobVertex[] tasks = eg.getAllVertices().values().toArray(new ExecutionJobVertex[2]);
for (int i = 0; i < NUM_TASKS; i++) {
CoLocationConstraint constr1 = tasks[0].getTaskVertices()[i].getLocationConstraint();
CoLocationConstraint constr2 = tasks[1].getTaskVertices()[i].getLocationConstraint();
assertNotNull(constr1.getSharedSlot());
assertTrue(constr1.isAssigned());
assertEquals(constr1, constr2);
}
}
Aggregations