@Override
    public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws
                                                                                              IOException,
                                                                                              ServletException {
        HttpServletRequest httpRequest = (HttpServletRequest) request; // NOSONAR
        HttpServletResponse httpResponse = (HttpServletResponse) response; // NOSONAR

        final String relativePath = FilterTools.getRelativePath(httpRequest, filterPath);

        if (LOG.isDebugEnabled()) {
            LOG.debug(relativePath);
        }

        HttpServletRequestWrapper requestWrapper = new HttpServletRequestWrapper(httpRequest) {
            @Override
            public String getPathInfo() {
                return relativePath;
            }

            @Override
            public String getRequestURI() {
                return relativePath;
            }
        };

        // handle static resources
        boolean consumed = StaticFilesConfiguration.servletInstance.consume(httpRequest, httpResponse);

        if (consumed) {
            return;
        }

        matcherFilter.doFilter(requestWrapper, response, chain);
    }
Returns the instances of {@link SparkApplication} which on which {@link SparkApplication#init() init()} will be called.
Default implementation looks up the class names in the filterConfig using the key {@value #APPLICATION_CLASS_PARAM}.
Subclasses can override this method to use different techniques to obtain an instance (i.e. dependency injection).

@param filterConfig the filter configuration for retrieving parameters passed to this filter.
@return the spark applications containing the configuration.
@throws ServletException if anything went wrong.
src/main/java/spark/servlet/SparkFilter.java