Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Java 8 bridge method handling can lead to false positive detection of autowired annotations [SPR-12187] #16801

spring-projects-issues opened this issue Sep 12, 2014 · 1 comment
in: core status: backported type: bug


Copy link

@spring-projects-issues spring-projects-issues commented Sep 12, 2014

Anton Ermolenko opened SPR-12187 and commented

Not actually false, but due to spring tries in inject dependencies into bridge methods in Java 8.

Test for annotations -
Results -

Due to this spring tries to inject dependencies into bridge methods.

Test app - for Spring - - works great on Java 7, fails on Java 8.

Affects: 3.2.11, 4.0.7, 4.1 GA

Reference URL:

Issue Links:

  • #13302 Bridged method detection leads to false positive detection of autowired annotations
  • #17053 Java 8 introspection causes breakage with FreeMarker Configuration bean
  • #17096 @Resource injection broken under spring-framework > 4.1.0
  • #17101 Consistent bridge method handling in annotation post-processors

Referenced from: commits ec3967a, f4219ca, 354c3e0, 29abca5

Backported to: 4.0.8, 3.2.13

Copy link
Collaborator Author

@spring-projects-issues spring-projects-issues commented Sep 18, 2014

Juergen Hoeller commented

As of 4.1.1, we're consistently excluding bridge methods in Spring's annotation post-processors now, not relying on bridge method resolution attempts like before.

I'm going to backport a minimal fix for the immediate problem to 4.0.8 as well.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
in: core status: backported type: bug
None yet

No branches or pull requests

2 participants