/** * Reload this web application, if reloading is supported. * <p> * <b>IMPLEMENTATION NOTE</b>: This method is designed to deal with * reloads required by changes to classes in the underlying repositories * of our class loader. It does not handle changes to the web application * deployment descriptor. If that has occurred, you should stop this * Context and create (and start) a new Context instance instead. * * @exception IllegalStateException if the <code>reloadable</code> * property is set to <code>false</code>. */ public synchronized void reload() { // Validate our current component state if (!started) return; // Stop accepting requests temporarily setPaused(true); try { stop(); } catch (LifecycleException e) { CatalinaLogger.CORE_LOGGER.errorStoppingContext(getName(), e); } try { start(); } catch (LifecycleException e) { CatalinaLogger.CORE_LOGGER.errorStartingContext(getName(), e); } setPaused(false); }