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 }}
Repository navigation
Introduce a pre-resolved target type in RootBeanDefinition [SPR-10335] #14969
It would be great if the RootBeanDefiniton would have a pre-resolved target type field, so that - if the target type is know beforehand - we do not have to resort to predicting it the various bean factories.
RootBeanDefinition has a public "setTargetType" method now. Make sure to use a RootBeanDefinition over a GenericBeanDefinition for setting that type in advance.
We also cache the resolved target type per bean definition for regular bean classes and factory methods now, which should deliver a performance benefit for non-singleton bean creation - in particular for beans defined on a configuration class.
Activity
spring-projects-issues commentedon Mar 1, 2013
Juergen Hoeller commented
RootBeanDefinition has a public "setTargetType" method now. Make sure to use a RootBeanDefinition over a GenericBeanDefinition for setting that type in advance.
We also cache the resolved target type per bean definition for regular bean classes and factory methods now, which should deliver a performance benefit for non-singleton bean creation - in particular for beans defined on a configuration class.
Juergen