I am trying to use histogram (Distribution Summary) using micrometer core and registry version 1.1.9. I am trying to capture score values that would lie between 0 and 1 and so need buckets between 0 and 1 and capture counts. But in this micrometer version, DistributionStatisticsConfig does not support double values for sla and minimumExpectedValue and maximumExpectedValue. So, is there any other way through which I can achieve this ?
long[] buckets = {1,2,3,4,5,6}
DistributionStatisticConfig.builder()
.percentilesHistogram(true)
.sla(buckets)
.percentiles(PERCENTILES)
.percentilePrecision(2)
.minimumExpectedValue(1l)
.maximumExpectedValue(1l)
.build();
As a workaround, I used scale factor as 10 for DistributionSummary
which then multiplied all score values by 10 (i.e. 0.11 got changed to 1.1). And to capture this, i created buckets from 1-10. Now the scores are getting captured properly. But I want to visualize this histogram in grafana and for that I want to report original score values. Is there a way to multiple (le)
values by any factor in Legend
section of grafana