Similarly to request in #78, please consider adding support for computing $perSecond for multiple series (hosts).
Currently, the $rateColumns computes something like:
SELECT t, arrayMap(a -> (a.1, a.2/runningDifference( t/1000 )), groupArr)
FROM (
SELECT t, groupArray((host, v)) as groupArr
....
Which does not produce correct results for metrics which only grows over time, as one needs to compute difference between two consequitive values v as well (not just time).
Unfortunatelly, doing runningDifference(a.2)/runningDifference(t/1000) does not work, as a.2 gets materialized to different values v between different columns (host).
I have been scratching my head for a while and I am not sure how to write such query in Clickhouse at all. I hope you know better :)
Similarly to request in #78, please consider adding support for computing $perSecond for multiple series (hosts).
Currently, the $rateColumns computes something like:
Which does not produce correct results for metrics which only grows over time, as one needs to compute difference between two consequitive values
vas well (not just time).Unfortunatelly, doing
runningDifference(a.2)/runningDifference(t/1000)does not work, asa.2gets materialized to different valuesvbetween different columns (host).I have been scratching my head for a while and I am not sure how to write such query in Clickhouse at all. I hope you know better :)