Examples of addUrlPatterns()


Examples of org.springframework.boot.context.embedded.FilterRegistrationBean.addUrlPatterns()

    public FilterRegistrationBean removeHeaderRegistration() {
        RemoveHeaderFilter rhf = new RemoveHeaderFilter();
        FilterRegistrationBean registrationBean = new FilterRegistrationBean(rhf);

        logger.info("Adding remove header filter!");
        registrationBean.addUrlPatterns("/*");

        return registrationBean;
    }
}
View Full Code Here

Examples of org.springframework.boot.context.embedded.FilterRegistrationBean.addUrlPatterns()

    public FilterRegistrationBean removeHeaderRegistration() {
        RemoveHeaderFilter rhf = new RemoveHeaderFilter();
        FilterRegistrationBean registrationBean = new FilterRegistrationBean(rhf);

        logger.info("Adding remove header filter!");
        registrationBean.addUrlPatterns("/*");

        return registrationBean;
    }
}
View Full Code Here

Examples of org.springframework.boot.context.embedded.FilterRegistrationBean.addUrlPatterns()

  }

  @Bean
  public FilterRegistrationBean gzipFilterRegistrationBean() {
    FilterRegistrationBean frb = new FilterRegistrationBean(new GZipServletFilter());
    frb.addUrlPatterns("*.css", "*.json", "*.html", "*.js", Api1.PATH + "*");
    frb.setAsyncSupported(true);
    frb.setEnabled(Config.GZIP_ENABLED);
    frb.setMatchAfter(true);
    frb.setOrder(20);
    return frb;
View Full Code Here

Examples of org.springframework.boot.context.embedded.FilterRegistrationBean.addUrlPatterns()

  }

  @Bean
  public FilterRegistrationBean corsFilterRegistrationBean() {
    FilterRegistrationBean frb = new FilterRegistrationBean(new CORSFilter());
    frb.addUrlPatterns(Api1.PATH + "*");
    frb.addInitParameter("cors.allowed.methods", "GET,POST,PUT,DELETE,HEAD,OPTIONS");
    frb.addInitParameter("cors.exposed.headers", "Cache-Control,Content-Length,Content-Type,Date,ETag,Expires");
    frb.addInitParameter("cors.allowed.headers", "Origin,Accept,X-Requested-With,Content-Type,"
        + "Access-Control-Request-Method,Access-Control-Request-Headers,X-Amz-Credential,"
        + "X-Amz-Date,Authorization");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.