• Brian Clozel's avatar
    Add option to configure PathPatternParser · 0f264b68
    Brian Clozel authored
    As of Spring Framework 5.3, it is now possible to use `PathPatternParser`
    to parse and match request mapping path patterns, as an alternative to
    the current default `AntPathMatcher`.
    
    This new implementation has been used for a while in Spring WebFlux and
    it’s been designed for consistency and performance.
    
    This commit introduces a new configuration property for opting-in this
    new variant:
    
    `spring.mvc.pathmatch.matching-strategy=path_pattern_parser`
    
    The default option is still `ant_path_matcher` for now, but we might
    change the default in future versions since Spring Framework considers
    it the best choice for modern applications.
    
    There are several behavior differences with this new variant:
    
    * double wildcards `"**"` are rejected when used in the middle patterns,
    this is only allowed as the last matching segment in a pattern.
    
    * it is incompatible with some path matching options, like
    suffix-pattern, registered-suffix-pattern or configuring a Servlet
    prefix on the `DispatcherServlet` (`spring.mvc.servlet.path=/test`)
    
    This commit introduces two `FailureAnalyzer` implementations to guide
    developers when facing those issues.
    
    Closes gh-21694
    0f264b68
Name
Last commit
Last update
.github Loading commit data...
buildSrc Loading commit data...
ci Loading commit data...
eclipse Loading commit data...
git/hooks Loading commit data...
gradle/wrapper Loading commit data...
idea Loading commit data...
spring-boot-project Loading commit data...
spring-boot-tests Loading commit data...
src Loading commit data...
.editorconfig Loading commit data...
.gitignore Loading commit data...
CODE_OF_CONDUCT.adoc Loading commit data...
CONTRIBUTING.adoc Loading commit data...
LICENSE.txt Loading commit data...
README.adoc Loading commit data...
SUPPORT.adoc Loading commit data...
build.gradle Loading commit data...
gradle.properties Loading commit data...
gradlew Loading commit data...
gradlew.bat Loading commit data...
settings.gradle Loading commit data...