micrometer-docs
micrometer-docs copied to clipboard
Timed annotation framework support and TimedAspect usage not clear enough
See https://github.com/micrometer-metrics/micrometer/issues/2930.
We've previously added clarification around this usage, but it could be more explicit that you should not use the TimedAspect AND Spring Boot's @Timed support, because it results in double instrumentation, potentially with the same meter name but different tags, which is notably a problem currently if you're using the Prometheus registry. Even if you're not using the Prometheus registry, though, you probably don't want the double instrumentation and meters for the same timing.