lindong28 commented on code in PR #22670: URL: https://github.com/apache/flink/pull/22670#discussion_r1244852829
########## flink-runtime/src/main/java/org/apache/flink/runtime/scheduler/SchedulerBase.java: ########## @@ -236,6 +239,16 @@ public SchedulerBase( this.exceptionHistory = new BoundedFIFOQueue<>( jobMasterConfiguration.getInteger(WebOptions.MAX_EXCEPTION_HISTORY_SIZE)); + + this.finishingTasks = createFinishingTasks(); + } + + private Map<JobVertexID, BitSet> createFinishingTasks() { + Map<JobVertexID, BitSet> map = new HashMap<>(); + for (ExecutionJobVertex vertex : getExecutionGraph().getAllVertices().values()) { + map.put(vertex.getJobVertexId(), new BitSet()); Review Comment: Suppose all subtasks of a job vertex have finished and then the job is restarted, will JM still allocate a slot to deploy this job vertex? If yes, then it seems like a waste of slot resource and we probably should fix it. Can you help provide the link to the code or doc that verifies the above behavior? -- 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: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org