akalash commented on code in PR #28999:
URL: https://github.com/apache/flink/pull/28999#discussion_r4721307082
##########
flink-runtime/src/test/java/org/apache/flink/runtime/scheduler/adaptive/RestartingTest.java:
##########
@@ -83,12 +83,15 @@ public void
testTransitionToSubsequentStateWhenResourceChanged(boolean hasDesire
throws Exception {
try (MockRestartingContext ctx = new MockRestartingContext()) {
JobVertexID jobVertexId = new JobVertexID();
- VertexParallelism availableParallelism =
+ // Only 1 slot is genuinely free (e.g. the slot backing the
just-cancelled execution
+ // has not been released yet), even though the restart target is
2: must not shortcut
+ // straight to CreatingExecutionGraph.
+ VertexParallelism parallelismBasedOnFreeSlots =
new VertexParallelism(singletonMap(jobVertexId, 1));
VertexParallelism requiredParallelismForForcedRestart =
new VertexParallelism(singletonMap(jobVertexId, 2));
- ctx.setAvailableVertexParallelism(availableParallelism);
+ ctx.setAchievableVertexParallelism(parallelismBasedOnFreeSlots);
ctx.setHasDesiredResources(hasDesiredResources);
Review Comment:
https://issues.apache.org/jira/browse/FLINK-41715
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]