tillrohrmann commented on a change in pull request #13829:
URL: https://github.com/apache/flink/pull/13829#discussion_r516103586



##########
File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/slotmanager/DeclarativeSlotManager.java
##########
@@ -200,10 +200,12 @@ public void suspend() {
                LOG.info("Suspending the slot manager.");
 
                resourceTracker.clear();
-               taskExecutorManager.close();
+               if (taskExecutorManager != null) {

Review comment:
       Maybe add `@Nullable` to `taskExecutorManager`.

##########
File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/slotmanager/DeclarativeSlotManager.java
##########
@@ -200,10 +200,12 @@ public void suspend() {
                LOG.info("Suspending the slot manager.");
 
                resourceTracker.clear();
-               taskExecutorManager.close();
+               if (taskExecutorManager != null) {

Review comment:
       Actually we should maybe also add `@Nullable` to `resourceManagerId` and 
`resourceActions`.

##########
File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/slotmanager/DeclarativeSlotManager.java
##########
@@ -200,10 +200,12 @@ public void suspend() {
                LOG.info("Suspending the slot manager.");

Review comment:
       we could also return if `started == false`.




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


Reply via email to