Till Westmann has submitted this change and it was merged. Change subject: stop application entry point ......................................................................
stop application entry point Change-Id: Ia4a8fab765f4878b30b6f7adb430f01ef2757605 Reviewed-on: https://asterix-gerrit.ics.uci.edu/827 Reviewed-by: Jenkins <[email protected]> Tested-by: Jenkins <[email protected]> Reviewed-by: Yingyi Bu <[email protected]> --- M hyracks-fullstack/hyracks/hyracks-control/hyracks-control-cc/src/main/java/org/apache/hyracks/control/cc/ClusterControllerService.java 1 file changed, 15 insertions(+), 4 deletions(-) Approvals: Yingyi Bu: Looks good to me, approved Jenkins: Looks good to me, but someone else must approve; Verified diff --git a/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-cc/src/main/java/org/apache/hyracks/control/cc/ClusterControllerService.java b/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-cc/src/main/java/org/apache/hyracks/control/cc/ClusterControllerService.java index 8fb83d1..2aa3f37 100644 --- a/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-cc/src/main/java/org/apache/hyracks/control/cc/ClusterControllerService.java +++ b/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-cc/src/main/java/org/apache/hyracks/control/cc/ClusterControllerService.java @@ -249,10 +249,7 @@ workQueue.start(); connectNCs(); LOGGER.log(Level.INFO, "Started ClusterControllerService"); - if (aep != null) { - // Sometimes, there is no application entry point. Check hyracks-client project - aep.startupCompleted(); - } + notifyApplication(); } private void startApplication() throws Exception { @@ -288,9 +285,17 @@ } } + private void notifyApplication() throws Exception { + if (aep != null) { + // Sometimes, there is no application entry point. Check hyracks-client project + aep.startupCompleted(); + } + } + @Override public void stop() throws Exception { LOGGER.log(Level.INFO, "Stopping ClusterControllerService"); + stopApplication(); webServer.stop(); sweeper.cancel(); workQueue.stop(); @@ -301,6 +306,12 @@ LOGGER.log(Level.INFO, "Stopped ClusterControllerService"); } + private void stopApplication() throws Exception { + if (aep != null) { + aep.stop(); + } + } + public ServerContext getServerContext() { return serverCtx; } -- To view, visit https://asterix-gerrit.ics.uci.edu/827 To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ia4a8fab765f4878b30b6f7adb430f01ef2757605 Gerrit-PatchSet: 6 Gerrit-Project: asterixdb Gerrit-Branch: master Gerrit-Owner: Till Westmann <[email protected]> Gerrit-Reviewer: Jenkins <[email protected]> Gerrit-Reviewer: Till Westmann <[email protected]> Gerrit-Reviewer: Yingyi Bu <[email protected]>
