Description
Bean definitions with instance supplier callbacks can't be supported by design on AOT as explained in spring-projects/spring-framework#29555. Spring Framework is going to document this and throw an exception during AOT processing of such bean via spring-projects/spring-framework#29556 instead of silently ignoring the instance supplier when a default constructor on the bean class is found.
While working on changing that behavior, I noticed a few Spring Boot beans are defining instance suppliers (there may be other ones, this is just on a simple app):
org.springframework.boot.context.properties.BoundConfigurationProperties
org.springframework.boot.web.server.WebServerFactoryCustomizerBeanPostProcessor
org.springframework.boot.web.server.ErrorPageRegistrarBeanPostProcessor
It currently works because the instance supplier references the bean class default constructor and because Spring Framework silently ignores them, but we would like to report proper error to the user when that's the case.
Could you please update Spring Boot codebase to remove the few usages of bean instance suppliers? I will also check the other project portfolio via the AOT smoke tests and reach the related teams.