Type: Enhancement

Currently, when creating a builder chain for HttpSecurity, and building FormLoginConfigurer inside of formLogin() method, 2 builder methods can be called in one chain: defaultSuccessUrl().<...>.successHandler(). But in reality, they are incompatible, because defaultSuccessUrl() creates its own successHandler inside, and calls successHandler() as well. So when we have these 2 orders in the chain: 1. defaultSuccessUrl().successHandler(): We lose the result of defaultSuccessUrl 2. .successHandler().defaultSuccessUrl(): We lose the result of successHandler

There are 2 possible solutions: - create a variant for defaultSuccessUrl which does not override the successHandler - create a variant for defaultSuccessUrl with successHandler as input parameter

Comment From: snicoll

This isn't the right place to report an issue to Spring Security. Please use the appropriate project: https://github.com/spring-projects/spring-security