Migrate AntPathRequestMatcher to PathPatternRequestMatcher
ProprietaryIn Spring Security 6.5, AntPathRequestMatcher is deprecated in favor of PathPatternRequestMatcher. This recipe migrates static method calls, constructor usage and their method references to the new pattern in both Java and Kotlin sources. It marks the code for a manual migration instead where there is no direct equivalent: the case-insensitive and UrlPathHelper overloads, antMatcher(HttpMethod), an HTTP method that may be null or empty at runtime, and patterns with ** in the middle.
io. moderne. java. spring. security6. MigrateAntPathRequestMatchermod run . --recipe= io. moderne. java. spring. security6. MigrateAntPathRequestMatcherInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.