@Timed annotation, which can be annotated on the methods generates dropwizard metrics with .total as a suffix.
This is not compatible with prometheus-metrics-instrumentation-dropwizard to export dropwizard metrics.
Since the io.prometheus.metrics.instrumentation.dropwizard.DropwizardExports class has a method fromSnapshotAndCount which sanitizes the metric name withPrometheusNaming.sanitizeMetricName(dropwizardName).
As a result it causes duplicate metric name exception when prometheus endpoint is invoked
@Timedannotation, which can be annotated on the methods generates dropwizard metrics with.totalas a suffix.This is not compatible with prometheus-metrics-instrumentation-dropwizard to export dropwizard metrics.
Since the
io.prometheus.metrics.instrumentation.dropwizard.DropwizardExportsclass has a methodfromSnapshotAndCountwhich sanitizes the metric name withPrometheusNaming.sanitizeMetricName(dropwizardName).As a result it causes duplicate metric name exception when prometheus endpoint is invoked