micrometer icon indicating copy to clipboard operation
micrometer copied to clipboard

Log delta count in addition to throughput in LoggingMeterRegistry

Open fstaudt opened this issue 5 months ago • 4 comments

Please describe the feature request. In LoggingMeterRegistry, instruments such as counter, timer and histogram are logged only with a throughput (e.g. throughput=0.016667/s).
I propose to add the count next to the throughput in the logs for those instruments (e.g. throughput=0.016667/s count=1).

Rationale For instruments such as counter, timer and histogram, throughput is not always the most useful information to log.
In some cases, users want to know the count as it is exported by other meter registries (e.g. OTLP).

Deriving the count from the throughput requires to know the step and it is not always obvious from logs (especially when logInactive is disabled).
Adding the count in the logs next to the throughput would make the logs more clear.

Additional context N/A

I can provide a PR if it is OK for you.

fstaudt avatar Oct 02 '24 16:10 fstaudt