metaswirl commented on a change in pull request #18169: URL: https://github.com/apache/flink/pull/18169#discussion_r785435594
########## File path: flink-runtime/src/main/java/org/apache/flink/runtime/taskexecutor/TaskManagerRunner.java ########## @@ -106,6 +107,8 @@ private static final int SUCCESS_EXIT_CODE = 0; @VisibleForTesting static final int FAILURE_EXIT_CODE = 1; + private static Thread shutdownHook; Review comment: Good points all around, thank you! I've changed the implementation accordingly. ########## File path: flink-yarn/src/main/java/org/apache/flink/yarn/YarnResourceManagerDriver.java ########## @@ -117,6 +118,8 @@ private TaskExecutorProcessSpecContainerResourcePriorityAdapter taskExecutorProcessSpecContainerResourcePriorityAdapter; + private Phaser trackerOfReleasedResources; Review comment: thanks :) ########## File path: flink-runtime/src/main/java/org/apache/flink/runtime/state/TaskExecutorStateChangelogStoragesManager.java ########## @@ -124,10 +124,12 @@ public void releaseStateChangelogStorageForJob(@Nonnull JobID jobId) { } public void shutdown() { - if (closed) { - return; + synchronized (this) { Review comment: good idea! -- 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