mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ben Mahler <benjamin.mah...@gmail.com>
Subject Re: Review Request 44473: Added decrement operator to Counter.
Date Thu, 10 Mar 2016 22:30:49 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44473/#review123017
-----------------------------------------------------------



It looks like we need to update the documentation at the top of Counter to reflect that we
intentionally left out decrementing, because we found that some metrics libraries and systems
have a counter type that only supports going up or potentially being reset to 0. For example:

http://lymph.readthedocs.org/en/latest/api/metrics_api.html#lymph.core.monitoring.metrics.Counter
https://prometheus.io/docs/concepts/metric_types/#counter
https://blog.pkhamre.com/understanding-statsd-and-graphite/

Think of a counter as something that just counts events that go by, in which context decrementing
doesn't apply. If we want this decrementing behavior, we probably want to distinguish it with
a new type of Metric. This is because users have asked for the ability to distinguish different
metric types (e.g. counter vs gauge) because some monitoring systems need to be told whether
it can be decremented.

Make sense?

- Ben Mahler


On March 9, 2016, 7:07 p.m., Cong Wang wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/44473/
> -----------------------------------------------------------
> 
> (Updated March 9, 2016, 7:07 p.m.)
> 
> 
> Review request for mesos, Ben Mahler, Ian Downes, Vinod Kone, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-4740
>     https://issues.apache.org/jira/browse/MESOS-4740
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Added decrement operator to Counter.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/metrics/counter.hpp a13cc7e18c8b23eae83c326d63874d9d2aaedc0d

>   3rdparty/libprocess/src/tests/metrics_tests.cpp b84dc8d858f58bc9f52b218b7153510417cf34c2

> 
> Diff: https://reviews.apache.org/r/44473/diff/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Cong Wang
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message