• Kirill Smelkov's avatar
    amari.kpi: Fix LogMeasure to handle multiple x.drb_stats messages in one period · 1b9d4e1a
    Kirill Smelkov authored
    When computing Measurements amari.kpi derives period from stats messages
    - for example 60s if `xamari xlog` was running with stats/60s. But
    inside that period there could be multiple x.drb_stats messages - for
    example if xlog was running with `stats/60s x.drb_stats/10s`.
    However the code was handling only the last such x.drb_stats instead of
    accumulating counters from there during the period.
    
    As the result, if. e.g. during the period there were 90B/9s and 2B/0.2s
    x.drb_stats events, only the latter was accounted giving wrong data for
    transmitted amount and transmission time.
    
    -> Fix it.
    1b9d4e1a
kpi.py 20.5 KB