Skip to content

Provide functionality similar to Spring Boot's BeanTypeRegistry #23056

Closed

Description

@philwebb

Spring Boot currently has an internal class called BeanTypeRegistry that is used by @ConditionalOnBean and @ConditionalOnMissingBean. We've have a recent issue where we need something similar, but rather than make it public in Spring Boot it might be better if Spring Framework could offer methods that we could use.

What we specifically need is a way to predict the bean type in a way that's very fast to call during condition evaluation and doesn't cause any early initialization of any beans (including FactoryBeans).


After some analysis, I'm going to split this issue up into a number of smaller parts:

Activity

  1. added
    status: waiting-for-triage
    on May 29, 2019
  2. tkvangorder commented on Jul 18, 2019

    @tkvangorder

    @philwebb Any movement on this issue? I could take a stab at PR for this, but I would need some guidance on which package to move the code and/or what to rename the BeanTypeRegistry such that it conforms to how things are organized in the core Spring framework.

  3. philwebb commented on Jul 18, 2019

    @philwebb
    MemberAuthor

    Thanks for the offer @tkvangorder but I'm already in the middle of trying various changes. We won't be able to migrate BeanTypeRegistry as it is, instead we need to look at changing some of the core BeanFactory implementations. Unfortunately that's quite a complex part of the codebase so it's taking some time.

  4. tkvangorder commented on Jul 18, 2019

    @tkvangorder

    yep, not for the faint of heart. 8) Make sense, thank you!

  5. self-assigned this
    on Jul 23, 2019
  6. added
    in: core
    type: enhancement
    and removed
    status: waiting-for-triage
    on Jul 23, 2019
  7. added this to the 5.2 RC1 milestone on Jul 23, 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