metrics-spring
metrics-spring copied to clipboard
Detect annotations on interfaces
If the @Timed
annotation is placed on the interface, the aspect isn't awoken (annotation must be placed on the implementation class).
This is problematic if you want to monitor Spring Data's repositories where there is no implementation.
In AnnotationFilter#matches
, you should use Spring's AnnotationUtils#findAnnotation
(or something like that) instead of method.isAnnotationPresent(clazz)
Tested on 3.0.1