Related to #32489, there is an inconsistency between @Autowired
injection point resolution and getBeanProvider
return values in that the former takes targetType
into account for generic FactoryBean
type resolution (in its second step in GenericTypeAwareAutowireCandidateResolver
) whereas the latter does not (due to the single type matching step in DefaultListableBeanFactory
itself). This can be brought in sync through letting a FactoryBean
instance go through the same matching steps as a regular bean instance with generics.