Micrometer: min statistic for distribution summaries and timers

Created on 21 Feb 2018  路  11Comments  路  Source: micrometer-metrics/micrometer

Most helpful comment

All 11 comments

Just wanted to be clear that there was a use for it before introducing. Seems like alerting on a min is a rare thing, but there is probably a real world case somewhere. What are you thinking of doing?

BTW, workaround is a P0 percentile:

@Test
void minimum() {
    DistributionSummary summary = DistributionSummary.builder("my.summary")
            .publishPercentiles(0)
            .register(new SimpleMeterRegistry());

    // dummy data
    for (int i = 1; i < 10; i++) {
        summary.record(i);
    }

    assertThat(summary.percentile(0)).isEqualTo(1);
}

Micrometer's client-side percentiles are designed to decay in the same way max does. P0 can be interpolated, but it's something.

Historical monitoring of snapshots (but not necessarily alert) a distribution summary for say ... minimum values for something like say ... request size. All the other relevant stats are there; just seems to be missing this one.

Reason I'm seeking concrete use cases is we should determine whether this is an always-on thing or an option to select. Leaning towards the latter unless there are an overwhelming number of use cases.

Request size has an interesting characteristic that it has a natural lower bound (request header size). Interestingly, it means request size essentially is never normally distributed and standard deviation is useless, but I digress...

Would you alert on min size?

My thought was to track request size only for something like POST or PUT; since as you say the natural lower bound for a GET or HEAD request would typically be just the header + query string.

In the case of using HTTP for incoming writes; I would only alert if the use case was below the expected minimum; if that is even knowable for a given use case ... and that really depends on the application imo.

Sounds like default off with an option to turn it on would be OK then?

Ya, I think that would work. Thanks!

This would be useful for the StackDriver Range aggregate as well.

When implemented, fix min statistic on Azure App Insights implementation as well. #441.

to enable the adjustments for Cloudwatch. i added min value to micrometer. on branch 1.3.x
pullrequest

Was this page helpful?
0 / 5 - 0 ratings