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

AnnotatedElementUtils fails to find type-level annotations on interfaces [SPR-12944] #17537

spring-issuemaster opened this issue Apr 22, 2015 · 1 comment


None yet
2 participants
Copy link

commented Apr 22, 2015

Sam Brannen opened SPR-12944 and commented

Issue Links:

  • #17300 AnnotatedElementUtils does not find annotations on methods in dynamic proxies
  • #17335 AnnotatedElementUtils fails to find annotations on abstract, bridge, or interface methods

Referenced from: commits 7f0f04d


This comment has been minimized.

Copy link
Collaborator Author

commented Apr 22, 2015

Sam Brannen commented

Fixed as described in GitHub commit 7f0f04d:

Support annotations on interfaces in AnnotatedElementUtils

This commit introduces support in AnnotatedElementUtils for finding
annotations declared on interfaces at the type level.

NB: this commit does not include support for finding annotations
declared on interface methods.

In order to maintain backward compatibility with @Transactional
annotation attribute processing, a new getAnnotationAttributes() method
has been added to AnnotatedElementUtils that provides a flag to control
whether interfaces should be searched.
SpringTransactionAnnotationParser and JtaTransactionAnnotationParser
have been updated accordingly to ensure that interfaces are not
unintentionally searched in the @Transactional resolution process.

This commit also introduces additional tests and updates TODOs for

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.