@Override public void close() throws Exception { if(twillRunner != null) { twillRunner.stop(); } }
@Override public void stop() { delegate.stop(); }
@Override public void stop() { delegate.stop(); }
public void invalidateTwillService(final ClusterId key) { TwillRunnerService service = twillRunners.remove(key); if (service != null) { service.stop(); } }
@Override public void close() throws Exception { for (TwillRunnerService twillRunner : twillRunners.values()) { twillRunner.stop(); } for (CuratorFramework curator : curators.values()) { curator.close(); } } }
@Override public void close() { for (TwillRunnerService twillRunner : twillRunners.values()) { twillRunner.stop(); } for (CuratorFramework curator : curators.values()) { curator.close(); } } }
@Override public void close() { for (TwillRunnerService twillRunner : twillRunners.values()) { twillRunner.stop(); } for (CuratorFramework curator : curators.values()) { curator.close(); } } }
/** * Stops a {@link TwillRunnerService}. No exception will be thrown even stopping failed. */ private static void stopQuietly(@Nullable TwillRunnerService service) { try { if (service != null) { LOG.debug("Stopping twill runner service"); service.stop(); LOG.info("Twill runner service stopped in master"); } } catch (Exception e) { LOG.warn("Exception when stopping service {}", service, e); } }
@Override public void run() { try { Futures.getUnchecked(controller.terminate()); } finally { twillRunner.stop(); } } });
@Override public void run() { try { Futures.getUnchecked(controller.terminate()); } finally { twillRunner.stop(); } } });
@Override public void run() { try { Futures.getUnchecked(controller.terminate()); } finally { twillRunner.stop(); } } });
@Override protected void after() { // Stop all runnable applications for (TwillRunner.LiveInfo info : twillRunner.lookupLive()) { for (TwillController controller : info.getControllers()) { try { controller.terminate().get(); } catch (Exception e) { LOG.warn("Exception raised when awaiting termination of {}", info.getApplicationName()); } } } try { twillRunner.stop(); } catch (Exception e) { LOG.warn("Failed to stop TwillRunner", e); } try { cluster.stop(); } catch (Exception e) { LOG.warn("Failed to stop mini Yarn cluster", e); } try { dfsCluster.shutdown(); } catch (Exception e) { LOG.warn("Failed to stop mini dfs cluster", e); } stopQuietly(zkServer); tmpFolder.delete(); }
remoteExecutionTwillRunnerService.stop(); serviceStore.stopAndWait();
remoteExecutionTwillRunnerService.stop(); serviceStore.stopAndWait();
newRunnerService.stop();
runnerService.stop();