microprofile metrics spec

61 views
Skip to first unread message

Avner Sternheim

unread,
Jan 5, 2020, 6:51:25 AM1/5/20
to Eclipse MicroProfile
Hi,

I have a question:
why did you add to @timer metric, metrics that can be calculated by Prometheus?

Example Timer JSON GET Response
{
  "responseTime": {
    "count": 29382,
    "meanRate":12.185627192860734,
    "oneMinRate": 12.563,
    "fiveMinRate": 12.364,
    "fifteenMinRate": 12.126,
    "min":169916,
    "max":5608694,
    "mean":415041.00024926325,
    "stddev":652907.9633011606,
    "p50":293324.0,
    "p75":344914.0,
    "p95":543647.0,
    "p98":2706543.0,
    "p99":5608694.0,
    "p999":5608694.0,
    "count;servlet=two": 29382,
    "meanRate;servlet=two":12.185627192860734,
    "oneMinRate;servlet=two": 12.563,
    "fiveMinRate;servlet=two": 12.364,
    "fifteenMinRate;servlet=two": 12.126,
    "min;servlet=two":169916,
    "max;servlet=two":5608694,
    "mean;servlet=two":415041.00024926325,
    "stddev;servlet=two":652907.9633011606,
    "p50;servlet=two":293324.0,
    "p75;servlet=two":344914.0,
    "p95;servlet=two":543647.0,
    "p98;servlet=two":2706543.0,
    "p99;servlet=two":5608694.0,
    "p999;servlet=two":5608694.0
  }
}

sending all those metrics, requires more storage in Prometheus.

Is there a true reason for that? and if not, can it be changed upon annotation configuration?


thanks,
Avner



Jan Martiška

unread,
Jan 6, 2020, 3:33:05 AM1/6/20
to Eclipse MicroProfile
Hi Avner,
this is a remnant from DropWizard metrics on top of which MP Metrics were originally based. We're aware that this metric is more complex than necessary and we're working to add a new metric named Simple Timer, it should be available in Metrics 2.3 - see [1] - that one will only keep track of the number of invocations and the total duration, so it will be much more lightweight. Feel free to comment on the issue/pull request if you have any suggestions.

[1] https://github.com/eclipse/microprofile-metrics/issues/496

Werner Keil

unread,
Jan 6, 2020, 2:21:27 PM1/6/20
to Eclipse MicroProfile
Hi,

See my remarks in https://github.com/eclipse/microprofile-metrics/issues/496 I would really rather refrain from duplicating annotations, can't it be configured somehow, either with a simple "calculate" flag or something similar?

Werner

Avner Sternheim

unread,
Jan 6, 2020, 3:23:08 PM1/6/20
to Eclipse MicroProfile
thanks, I added my comment.
Reply all
Reply to author
Forward
0 new messages