Skip to content

Avoid double proxying for @Resource @Lazy fallback autowiring #31447

Closed
@jhoeller

Description

@jhoeller

The @Lazy support for @Resource injection points (as implemented in CommonAnnotationBeanPostProcessor) can lead to double proxying in case of fallback autowiring when no bean of the given name could be found, since DefaultListableBeanFactory.resolveDependency performs its own lazy proxy resolution in such a scenario. Addressing this through a refactored resolution algorithm also aligns with our upcoming AOT support for @Resource (#29614).

Metadata

Metadata

Assignees

Labels

in: coreIssues in core modules (aop, beans, core, context, expression)type: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions