Skip to content

Fix: PathRoutePredicateFactory matchTrailingSlash with Spring Framework 7.0 - #4245

Open
renechoi wants to merge 3 commits into
spring-cloud:mainfrom
renechoi:fix-4212
Open

Fix: PathRoutePredicateFactory matchTrailingSlash with Spring Framework 7.0#4245
renechoi wants to merge 3 commits into
spring-cloud:mainfrom
renechoi:fix-4212

Conversation

@renechoi

Copy link
Copy Markdown

Fixes #4212.

In Spring Framework 7.0, PathPatternParser.setMatchOptionalTrailingSeparator() was removed, meaning the matchTrailingSlash setting in PathRoutePredicateFactory silently had no effect. This change implements trailing slash tolerance natively in PathRoutePredicateFactory by falling back to matching the path without the trailing slash when matchTrailingSlash is enabled, preserving the original one-directional semantics.

renechoi added 2 commits July 24, 2026 14:24
…k 7.0

Signed-off-by: renechoi <renechoi90@gmail.com>
Signed-off-by: renechoi <renechoi90@gmail.com>
Signed-off-by: kdelay <kdelay20@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PathRoutePredicateFactory: matchTrailingSlash has no effect since Spring Framework 7.0

3 participants