Commit 108dca55 authored by Maxim's avatar Maxim
Browse files

Enable Jetty GZIP

parent e3209f77
......@@ -38,6 +38,7 @@ import org.springframework.web.filter.CharacterEncodingFilter;
import org.springframework.web.filter.DelegatingFilterProxy;
import org.springframework.web.servlet.DispatcherServlet;
import org.tuckey.web.filters.urlrewrite.UrlRewriteFilter;
import org.tuckey.web.filters.urlrewrite.gzip.GzipFilter;
public class WebAppInitializer implements WebApplicationInitializer {
......@@ -180,5 +181,11 @@ public class WebAppInitializer implements WebApplicationInitializer {
newGUIFilter.setInitParameter("exclude-paths", "/html /login-attempt");
newGUIFilter.addMappingForUrlPatterns(null, false, "/*");
// GZip filter configuration
FilterRegistration.Dynamic gZIPFilter = servletContext
.addFilter("gZIPFilter", GzipFilter.class);
gZIPFilter.addMappingForUrlPatterns(null, false, "/html/*");
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment