New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Auto-configure HandlerMethodArgumentResolvers on AnnotatedControllerConfigurer #40393
base: main
Are you sure you want to change the base?
Auto-configure HandlerMethodArgumentResolvers on AnnotatedControllerConfigurer #40393
Conversation
… to modify the AnnotatedControllerConfigurer. End users could provide HandlerMethodArgumentResolvers without having to override the entire AnnotatedControllerConfigurer bean.
I see that the build fails on a missing |
@maxhov I'm afraid we'll probably not get this into 3.3 since we just cut RC1, but feel free to use that as the |
Why not auto-configure HandlerMethodArgumentResolver beans on that component in the existing configuration? To me customizers are useful when lots of options exist and when applications want to contribute several. |
@bclozel I chose this approach because it is also used for |
The I think that as a first step, we should consider |
@bclozel I am not sure I understand. Registering either Maybe exposing more methods on the |
Add an
AnnotatedControllerConfigurerCustomizer
to provide a friendly API to modify the autoconfiguredAnnotatedControllerConfigurer
. End users could provideHandlerMethodArgumentResolver
s without having to override the entireAnnotatedControllerConfigurer
bean.This has been discussed in (amongst others) spring-projects/spring-graphql#603, but there seems no way to customize the
AnnotatedControllerConfigurer
. This PR aims to improve the API for end users.