public static void clearCache() { OgnlRuntime.clearCache(); clearOGNLCache("cacheGetMethod"); clearOGNLCache("cacheSetMethod"); }
public static void clearCache() { OgnlRuntime.clearCache(); clearOGNLCache("cacheGetMethod"); clearOGNLCache("cacheSetMethod"); }
/** * 登録済みのリソースを全て破棄します。 * <p> * 登録済みのリソースを全て破棄した後,{@link org.seasar.framework.log.Logger#dispose()}を呼び出します。 * commons loggingがクラスローダへの参照を保持するため、この呼び出しが必要となります。 * リソースの破棄中にログが出力される場合を考慮して、 リソースを破棄した後に{@link org.seasar.framework.log.Logger#dispose()}を呼び出します。 * </p> */ public static synchronized void dispose() { while (!disposables.isEmpty()) { final Disposable disposable = (Disposable) disposables.removeLast(); try { disposable.dispose(); } catch (final Throwable t) { t.printStackTrace(); // must not use Logger. } } disposables.clear(); OgnlRuntime.clearCache(); Introspector.flushCaches(); Logger.dispose(); }
/** * 登録済みのリソースを全て破棄します。 * <p> * 登録済みのリソースを全て破棄した後,{@link org.seasar.framework.log.Logger#dispose()}を呼び出します。 * commons loggingがクラスローダへの参照を保持するため、この呼び出しが必要となります。 * リソースの破棄中にログが出力される場合を考慮して、 リソースを破棄した後に{@link org.seasar.framework.log.Logger#dispose()}を呼び出します。 * </p> */ public static synchronized void dispose() { while (!disposables.isEmpty()) { final Disposable disposable = (Disposable) disposables.removeLast(); try { disposable.dispose(); } catch (final Throwable t) { t.printStackTrace(); // must not use Logger. } } disposables.clear(); OgnlRuntime.clearCache(); Introspector.flushCaches(); Logger.dispose(); }
public void registryDidShutdown() { try { _contextPool.clear(); _contextPool.close(); OgnlRuntime.clearCache(); Introspector.flushCaches(); } catch (Exception et) { // ignore } }
public void registryDidShutdown() { try { _contextPool.clear(); _contextPool.close(); OgnlRuntime.clearCache(); Introspector.flushCaches(); } catch (Exception et) { // ignore } }
/** * Deletes the given template. The service is unregistered, and the cache is cleared. * * @param template the template */ public void deleteTemplate(ThymeLeafTemplateImplementation template) { // 1 - unregister the service try { ServiceRegistration reg = registrations.remove(template); if (reg != null) { reg.unregister(); } } catch (Exception e) { //NOSONAR // May already have been unregistered during the shutdown sequence. } // 2 - as templates can have dependencies, and expressions kept in memory, we clear all caches. // Despite this may really impact performance, it should not happen too often on real systems. synchronized (this) { engine.getCacheManager().clearAllCaches(); } OgnlRuntime.clearCache(); // Unfortunately, the previous method do not clear the get and set method cache // (ognl.OgnlRuntime.cacheGetMethod and ognl.OgnlRuntime.cacheSetMethod) clearMethodCaches(); }