Follow the discussion in this PR.
Currently, ResourceManager#internalDeregisterApplication is a blocking call, so all the specific deployment implementation will do the Flink cluster deregister synchronously.
FLINK-17024, we could get a safe thread pool to execute the I/O operations, including the "deregister". This ticket is to make the interface asynchronous. Benefit from this, the shutdown process will be a little faster.