protected void reloadIfNecessary() throws ServletException { // TODO: Allow finer grained control of reload strategies: // - don't check file timestamp on every single request (once per N seconds). // - periodically check in background, instead of blocking request threads. if (autoReload && reloadRequired()) { synchronized (configLock) { // Double check lock for performance (works in JDK5+, with volatile items). if (reloadRequired()) { deployNewFilter(setup()); } } } }
protected void reloadIfNecessary() throws ServletException { // TODO: Allow finer grained control of reload strategies: // - don't check file timestamp on every single request (once per N seconds). // - periodically check in background, instead of blocking request threads. if (autoReload && reloadRequired()) { synchronized (configLock) { // Double check lock for performance (works in JDK5+, with volatile items). if (reloadRequired()) { deployNewFilter(setup()); } } } }