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



clients/src/main/java/org/apache/kafka/common/metrics/stats/SampledStat.java
<https://reviews.apache.org/r/34170/#comment134723>

    I think this is a good catch.
    
    Just so I understand, this is adding new samples for blank intervals of 
time when record was not called. As an optimization, I think you should only 
add "MetricConfig.samples" number of samples. In the rare case, there is no 
activity for 10 mins (say), this will add 10sec*6*10 = 600 samples which will 
be purged immediately on the next record call.


- Aditya Auradkar


On May 13, 2015, 10:32 p.m., Dong Lin wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/34170/
> -----------------------------------------------------------
> 
> (Updated May 13, 2015, 10:32 p.m.)
> 
> 
> Review request for kafka.
> 
> 
> Bugs: KAFKA-2191
>     https://issues.apache.org/jira/browse/KAFKA-2191
> 
> 
> Repository: kafka
> 
> 
> Description
> -------
> 
> KAFKA-2191; Measured rate should not be infinite
> 
> 
> Diffs
> -----
> 
>   clients/src/main/java/org/apache/kafka/common/metrics/stats/Rate.java 
> 98429da34418f7f1deba1b5e44e2e6025212edb3 
>   
> clients/src/main/java/org/apache/kafka/common/metrics/stats/SampledStat.java 
> b341b7daaa10204906d78b812fb05fd27bc69373 
> 
> Diff: https://reviews.apache.org/r/34170/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Dong Lin
> 
>

Reply via email to