Github user GJL commented on a diff in the pull request:

    https://github.com/apache/flink/pull/5354#discussion_r164438991
  
    --- Diff: 
flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/slotmanager/SlotManager.java
 ---
    @@ -485,7 +477,10 @@ protected TaskManagerSlot 
findMatchingSlot(ResourceProfile requestResourceProfil
                        TaskManagerSlot taskManagerSlot = 
iterator.next().getValue();
     
                        // sanity check
    -                   Preconditions.checkState(taskManagerSlot.getState() == 
TaskManagerSlot.State.FREE);
    +                   Preconditions.checkState(
    --- End diff --
    
    If you want, you can also use this overload:
    ```
    public static void checkState(boolean condition,
                        @Nullable String errorMessageTemplate,
                        @Nullable Object... errorMessageArgs)```


---

Reply via email to