Skip to content

Introduce a pre-resolved target type in RootBeanDefinition [SPR-10335] #14969

Closed

Description

@spring-projects-issues

Arjen Poutsma opened SPR-10335 and commented

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.


Issue Links:

Referenced from: commits c986a1e

Activity

  1. spring-projects-issues commented on Mar 1, 2013

    @spring-projects-issues
    CollaboratorAuthor

    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

  2. added
    type: enhancement
    in: core
    on Jan 11, 2019
  3. added this to the 3.2.2 milestone on Jan 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

in: coretype: enhancement

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions