component.stop();
public void stop() { try { LOGGER.info("stopping broker topic observers"); for (String key : _kafkaBrokerTopicObserverMap.keySet()) { try { KafkaBrokerTopicObserver observer = _kafkaBrokerTopicObserverMap.get(key); observer.stop(); } catch (Exception e) { LOGGER.error("Failed to stop KafkaBrokerTopicObserver: {}!", key); } } LOGGER.info("stopping api component"); _component.stop(); LOGGER.info("stopping resource manager"); _helixMirrorMakerManager.stop(); } catch (final Exception e) { LOGGER.error("Caught exception", e); } }
@Override public void stopServer() throws Exception { component.stop(); } }
private Component component; public void start(BundleContext bundleContext) throws Exception { bundleContext.addFrameworkListener(new FrameworkListener() { component = new Component(); (...) component.start(); }); } public void stop(BundleContext bundleContext) throws Exception { component.stop(); }
public synchronized void stop() throws Exception { if (started) { LOG.info("Stopping DCC Agent..."); started = false; if (ctx != null) { Component restletComponent = (Component) ctx.getBean("restletComponent"); restletComponent.stop(); LOG.debug("Closing Spring application context"); ctx.close(); ctx = null; } LOG.info("DCC Agent stopped"); } }
public void stop() { try { LOGGER.info("Stopping source kafka cluster validation manager"); _srcKafkaValidationManager.stop(); LOGGER.info("Stopping API component"); _component.stop(); LOGGER.info("Stopping helix manager"); _controllerHelixManager.stop(); } catch (final Exception e) { LOGGER.error("Caught exception", e); } }
public synchronized void stop() { LOG.info("Stopping helixAdminWebApp"); try { _component.stop(); LOG.info("Stopped helixAdminWebApp"); } catch (Exception e) { LOG.error("Exception in stopping helixAdminWebApp", e); } finally { if (_zkClient != null) { _zkClient.close(); } if (_rawZkClient != null) { _rawZkClient.close(); } } } }
@Override public void stop() throws Exception { UMLG.get().close(); UMLG.remove(); super.stop(); }
_component.stop(); } catch (Exception e) { LOGGER.error("Failed to stop api component", e);
@Override public void destroy() { if ((getComponent() != null) && (getComponent().isStarted())) { try { getComponent().stop(); } catch (Exception e) { log("Error during the stopping of the Restlet Component", e); } } super.destroy(); }
@Override public void destroy() { if ((getComponent() != null) && (getComponent().isStarted())) { try { getComponent().stop(); } catch (Exception e) { log("Error during the stopping of the Restlet Component", e); } } super.destroy(); }
/** * Stop and nullify the test server object after each test. * * NOTE: Does not clear any databases. * * @throws Exception */ @After public void tearDown() throws Exception { // Stop the component if(this.component != null) { this.component.stop(); } // nullify the reference to the component this.component = null; }
component.stop();
public static void main(String[] args) throws Exception { // create Component (as ever for Restlet) final Component comp = new Component(); final Server server = comp.getServers().add(Protocol.HTTP, 80); // create JAX-RS runtime environment final JaxRsApplication application = new JaxRsApplication(comp .getContext().createChildContext()); // attach ApplicationConfig application.add(new ExampleApplication()); // Attach the application to the component and start it comp.getDefaultHost().attach(application); comp.start(); System.out.println("Server started on port " + server.getPort()); System.out.println("Press key to stop server"); System.in.read(); System.out.println("Stopping server"); comp.stop(); System.out.println("Server stopped"); } }
getHelped().stop(); } else { Filter filter = null;