List of usage examples for org.apache.commons.chain CatalogFactory clear
public static void clear()
Clear all references to registered catalogs, as well as to the relevant class loader.
From source file:info.magnolia.commands.CommandsManager.java
/** * Clear all catalogues */ protected void onClear() { CatalogFactory.clear(); }
From source file:org.apache.struts.action.ActionServlet.java
/** * <p>Gracefully shut down this controller servlet, releasing any * resources that were allocated at initialization.</p> *//*from w w w. j av a2 s .c om*/ public void destroy() { if (log.isDebugEnabled()) { log.debug(internal.getMessage("finalizing")); } destroyModules(); destroyInternal(); getServletContext().removeAttribute(Globals.ACTION_SERVLET_KEY); // Release our LogFactory and Log instances (if any) ClassLoader classLoader = Thread.currentThread().getContextClassLoader(); if (classLoader == null) { classLoader = ActionServlet.class.getClassLoader(); } try { LogFactory.release(classLoader); } catch (Throwable t) { ; // Servlet container doesn't have the latest version // of commons-logging-api.jar installed // :FIXME: Why is this dependent on the container's version of // commons-logging? Shouldn't this depend on the version packaged // with Struts? /* Reason: LogFactory.release(classLoader); was added as an attempt to investigate the OutOfMemory error reported on Bugzilla #14042. It was committed for version 1.136 by craigmcc */ } CatalogFactory.clear(); PropertyUtils.clearDescriptors(); }
From source file:org.apache.struts.chain.legacy.CatalogConfiguratorPlugIn.java
/** * <p>Clean up at web application shutdown.</p> */ public void destroy() { CatalogFactory.clear(); }
From source file:org.seasar.struts.hotdeploy.impl.ChainConfigLoaderImpl.java
public void load() throws ServletException { initChain();/* w w w.ja v a 2 s . c om*/ DisposableUtil.add(new Disposable() { public void dispose() { CatalogFactory.clear(); } }); }