EdColeman commented on issue #4498:
URL: https://github.com/apache/accumulo/issues/4498#issuecomment-2101412344

   The tension between a counter and a gauge is what the intended usage is.
   
   Your interpretation seems to be that the by_type should be a snapshot of an 
instant in time.  That is not necessarily incorrect.
   
   Using a counter provides a different view.  Because a counter is always 
increasing you can reason about things between measurements.  It is not the 
instantaneous value  but the absolute value that is reported.  The absolute 
value allows using the delta and the rate of change of the value over time to 
be determined.  The counter answers how many X's have ever occurred. 
   
   For example, how many compactions have occurred over the last T?  One way 
the counter is useful - say you look at an instantaneous snapshot and there are 
0 compactions.  No problem, that seems normal.  However, if you looked over the 
last 24 hours and there were never any compactions you might need to look at 
things.  
   
   The counter allows you to look at things like how many compactions happened 
over the last reporting period - has that increased?  Counters also allow you 
to aggregate between reporting periods.  With a snapshot you just need to hope 
that it hits at the measurement time. 
   
   A counter also provides a way to trend things.  For example you may want to 
trend bulk imports - Is there a surge at certain times?  Does it vary by day? A 
counter can answer that, a gauge cannot.
   
   Using a combination of gauges (a snapshot of state) as well as counters to 
provide for trending and history may be appropriate.  Think how it would be 
displayed on a dashboard.  The gauges are the state right now.  The counters 
could be graphs. showing the activity over the last few hours.
   
   So using a counter provides a view into activity over-time.  Which is also 
not incorrect.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to