Skip to content

Avoid unnecessary CGLIB processing on configuration classes #34486

Closed

Description

@jhoeller

If a @Configuration class does not declare (or inherit) any instance-level @Bean methods, generating an enhanced subclass with CGLIB is not adding any value. This is particularly likely for "holder"-like configuration classes with just imports, not least of it all common @SpringBootApplication classes. We can entirely skip CGLIB processing for such classes, also not incurring unnecessary potential for CGLIB class cache failures/fallbacks (#34423).

Activity

  1. added
    in: core
    type: enhancement
    on Feb 25, 2025
  2. added this to the 6.2.4 milestone on Feb 25, 2025
  3. self-assigned this
    on Feb 25, 2025
  4. added
    status: backported
    and removed on Feb 25, 2025
  5. added a commit that references this issue on Feb 25, 2025
    aff9ac7
  6. added a commit that references this issue on Feb 25, 2025
    ea419d2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

in: corestatus: backportedtype: enhancement

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions