/** * Stops the server when closed */ @Override default void close() { stop(); }
public void stop() { furnace.stop(); } }
@PreDestroy public void destroy() { furnace.stop(); } }
@PreDestroy public void destroy() { furnace.stop(); } }
@PreDestroy public void destroy() { furnace.stop(); } }
@Override public void terminate() throws RemoteException { furnace.stop(); try { Thread.sleep(5000); } catch (InterruptedException e) { } Runtime.getRuntime().halt(1); }
@Override public void terminate() throws RemoteException { furnace.stop(); try { Thread.sleep(5000); } catch (InterruptedException e) { } Runtime.getRuntime().halt(1); }
@SuppressWarnings("unused") private void stop() { if (furnace != null && !furnace.getStatus().isStopped()) furnace.stop(); }
@SuppressWarnings("unused") private void stop() { if (furnace != null && !furnace.getStatus().isStopped()) furnace.stop(); }
private void stop() { if (furnace != null && !furnace.getStatus().isStopped()) furnace.stop(); while (!containerStatusListener.getContainerStatus().isStopped()) { try { Thread.sleep(10); } catch (InterruptedException e) { System.err.println("Failure waiting for Furnace to shutdown: " + e.getMessage()); e.printStackTrace(); } } }
private void stop() { if (furnace != null && !furnace.getStatus().isStopped()) furnace.stop(); while (!containerStatusListener.getContainerStatus().isStopped()) { try { Thread.sleep(10); } catch (InterruptedException e) { System.err.println("Failure waiting for Furnace to shutdown: " + e.getMessage()); e.printStackTrace(); } } }
public void destroy(BeanManager beanManager) { LOG.info("Shutting down furnace!"); beanManager.fireEvent(new FurnaceShutdownEvent()); if (furnace != null) { FurnaceProducerFurnaceShutdownListener listener = new FurnaceProducerFurnaceShutdownListener(); furnace.addContainerLifecycleListener(listener); furnace.stop(); // make sure it is stopped while (!listener.shutdownComplete) { try { Thread.sleep(100); } catch (Throwable t) { return; } } } }
@Override public Result execute(UIExecutionContext context) throws Exception { UIContext uiContext = context.getUIContext(); Shell shell = (Shell) uiContext.getProvider(); shell.getConsole().stop(); forge.stop(); uiContext.getAttributeMap().put("org.jboss.forge.exit", Boolean.TRUE); return Results.success(); } }