zhengcanbin edited a comment on pull request #12003: URL: https://github.com/apache/flink/pull/12003#issuecomment-625639474
> @zhengcanbin Thanks for chiming in and give your suggestion. When the application finished, the K8s resources will be destroyed automatically via `KubernetesResourceManager#internalDeregisterApplication`. It is the same behavior with Yarn deployment. There's a chance that the K8s resources couldn't be cleaned up except that the replica of the Deployment scales down to 0. This is due to the fabric8 SDK implementation on how to delete a Deployment. It split the procedure into three steps as follows: 1. Scales down the replica to 0 2. Wait until the scaling down succeed 3. Delete the ReplicaSet After step2, the JobManager process may already exit, and step3 could never be executed anymore thus leaving all the K8s resources not cleaned up. ---------------------------------------------------------------- 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]
