You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 23, 2023. It is now read-only.
When an application that uses @WebFilter and @ServletComponentScan to automatically register and autowire servlet filters (rather than defining beans of type FilterRegistrationBean) is made native, it fails to start, with the following error:
***************************
APPLICATION FAILED TO START
***************************
Description:
Native reflection configuration for java.lang.Object.<init>(com.example.demo.Foo) is missing.
Action:
Native configuration for a method accessed reflectively is likely missing.
You can try to configure native hints in order to specify it explicitly.
See https://docs.spring.io/spring-native/docs/current/reference/htmlsingle/#native-hints for more details.
Here's a minimal repro (create with Spring initializr, with Kotlin, gradle and Web). This code works as expected in normal, non-native mode.
The problem seems to be that the inner bean has not been post-processed the same way as regular "root" beans and its beanClass attribute has not been resolved. I am working on a fix.
snicoll
changed the title
ServletComponentScan seems to be unsupported
Inner bean definition's beanClass may not be resolved and generated with Object rather than the target type
Feb 8, 2022
When an application that uses
@WebFilter
and@ServletComponentScan
to automatically register and autowire servlet filters (rather than defining beans of typeFilterRegistrationBean
) is made native, it fails to start, with the following error:Here's a minimal repro (create with Spring initializr, with Kotlin, gradle and Web). This code works as expected in normal, non-native mode.
The text was updated successfully, but these errors were encountered: