Micrometer: Timer counts not published to Stackdriver

Created on 9 Apr 2019  路  8Comments  路  Source: micrometer-metrics/micrometer

The Micrometer documentation recommends

Never count something you can time with a聽Timer聽or summarize with a聽DistributionSummary! Both聽Timer聽and聽DistributionSummary聽always publish a count of events in addition to other measurements.

However, the Stackdriver backend doesn't seem to publish timer counts. I can't find them in Stackdriver and I don't see where they would be created in the code.

Can we add an additional Stackdriver metric (my.timer.count) when we publish timer durations?

bug stackdriver

Most helpful comment

Thanks to the pull request from @ormanli, a separate count will be published for Timers from version 1.1.5. Feel free to try out snapshots in the meantime, though the release should be coming very soon.

All 8 comments

Counts are published with the Stackdriver Distribution that we send for all DistributionSummary metrics (including Timers).

Thanks for the link! I'm new to Stackdriver

I see my metric in the Stackdriver UI with value type "Distribution", but there doesn't seem to any way to visualize the count in a line chart in Metrics Explorer.

Assuming I'm not overlooking something, would I need to create a separate Counter if I need to visualize counts?

Thanks for the link! I'm new to Stackdriver

I'm also new to Stackdriver, and I'm not sure the best way to visualize the count included in the Distribution. If we can find some resources on that, let's link them here for anyone else that finds this issue looking for the same thing. Stackdriver support resources are probably the best place to look for this, though. If for some reason the count in the Distribution cannot be visualized, we can then consider publishing a separate time series for count.

I found this, which suggests that you can't do anything extra with a distribution other than build a heat map and visualize percentiles.

I'll see if I can't get in touch with support as well

@shakuzen or @johnzeringue were you able to figure this out?

@joshfermin I never reached out to GCP support, but I'm pretty sure you can't plot the counts associated with distributions. If you look at built-in metrics for BigQuery, there are separate query/count and query/execution_times metrics. I still think Micrometer needs to publish a separate count metric too.

Bummer, I guess the workaround for now is to add a separate count metric in addition to my timer. Thanks for the update though.

Thanks to the pull request from @ormanli, a separate count will be published for Timers from version 1.1.5. Feel free to try out snapshots in the meantime, though the release should be coming very soon.

Was this page helpful?
0 / 5 - 0 ratings