GJL commented on a change in pull request #6785: [FLINK-10309][rest] Before
shutting down cluster, wait for asynchronous operations
URL: https://github.com/apache/flink/pull/6785#discussion_r224104240
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/entrypoint/component/DispatcherResourceManagerComponent.java
##########
@@ -126,65 +125,77 @@ public T getDispatcher() {
return webMonitorEndpoint;
}
- @Override
- public CompletableFuture<Void> closeAsync() {
+ /**
+ * Deregister the Flink application from the resource management system
by signalling
+ * the {@link ResourceManager}.
+ *
+ * @param applicationStatus to terminate the application with
+ * @param diagnostics additional information about the shut down, can
be {@code null}
+ * @return Future which is completed once the shut down
+ */
+ public CompletableFuture<Void> deregisterApplicationAndClose(
+ final ApplicationStatus applicationStatus,
+ final @Nullable String diagnostics) {
+
if (isRunning.compareAndSet(true, false)) {
- Exception exception = null;
+ final CompletableFuture<Void>
closeWebMonitorAndRegisterAppFuture =
Review comment:
typo: _DeregisterApp_
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services