@Override public void run() { System.out.println( "/n>>> About to execute: " + Runner.class.getName() + ".run() to clean up before JV"); if (webapp.isStarted()) { try { webapp.stop(); } catch (Exception e) { e.printStackTrace(); } } if (connector.isStarted()) { try { connector.stop(); } catch (Exception e) { e.printStackTrace(); } } if (server.isStarted()) { try { server.stop(); } catch (Exception e) { e.printStackTrace(); } } System.out.println(">>> Finished execution: " + Runner.class.getName() + ".run()"); }