HuangZhenQiu commented on a change in pull request #7356: 
[FLINK-10868][flink-yarn] Enforce maximum TMs failure rate in ResourceManagers
URL: https://github.com/apache/flink/pull/7356#discussion_r291899464
 
 

 ##########
 File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/slotmanager/SlotManager.java
 ##########
 @@ -300,6 +305,25 @@ public boolean registerSlotRequest(SlotRequest 
slotRequest) throws SlotManagerEx
                }
        }
 
+       /**
+        * Rejects all pending slot requests.
+        * @param cause the exception caused the rejection
+        */
+       public void rejectAllPendingSlotRequests(Exception cause) {
+               for (PendingSlotRequest pendingSlotRequest : 
pendingSlotRequests.values()) {
+                       rejectPendingSlotRequest(pendingSlotRequest, cause);
+
+                       // notify each job master about this exception
+                       resourceActions.notifyAllocationFailure(
 
 Review comment:
   If you see other part of the class. resourceActions.notifyAllocationFailure 
are called separately. How about keep the same pattern here?

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to