You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/08/11 04:18:43 UTC

[GitHub] [flink] xintongsong commented on a change in pull request #13051: [FLINK-18760][runtime] Redundant task managers should be released when there's no job running in session cluster

xintongsong commented on a change in pull request #13051:
URL: https://github.com/apache/flink/pull/13051#discussion_r468315396



##########
File path: flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/slotmanager/SlotManagerImpl.java
##########
@@ -1256,7 +1256,10 @@ void checkTaskManagerTimeoutsAndRedundancy() {
 			}
 
 			int slotsDiff = redundantTaskManagerNum * numSlotsPerWorker - freeSlots.size();
-			if (slotsDiff > 0) {
+			if (freeSlots.size() == slots.size()) {

Review comment:
       If the job failover takes long, then all the idle task managers will timeout and be released. There's few benefit keeping the redundant task managers, since we need to wait for re-launching the other task managers anyway. (Assuming the job needs more task managers than the redundant ones to execute.)




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org