You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 23, 2023. It is now read-only.
When using groupByNodes() in Metrictank the order of the returned series is randomized because the order is determined by the order in which keys get read from this map, and Go randomizes the map key order:
This can lead to issues if the return value of groupByNodes() is used as input for another function for which the order is relevant. We have observed a user who's using the output of groupByNodes() as input for divideSeriesLists(), which has lead to wrong results once we switched to Metrictank function processing.
The text was updated successfully, but these errors were encountered:
the main reason why it should always match graphite is for backwards compatibility, because otherwise queries may end up returning wrong results in a situation like divideSeriesLists(groupByNodes(...), <some other list of metrics>).
f.e. if you call groupByNodes() on 2 metrics and it returns 2 metrics (so no aggregation has been done), then the returned 2 metrics are going to be in the same order as the input metrics were passed into groupByNodes().
When using
groupByNodes()
in Metrictank the order of the returned series is randomized because the order is determined by the order in which keys get read from this map, and Go randomizes the map key order:metrictank/expr/func_groupbynodes.go
Line 73 in 487e2d4
In graphite the order is guaranteed to be the order in which keys got generated, to do this it is using a list here:
https://github.com/graphite-project/graphite-web/blob/4ce727593e949554cf1653ec7a42280a4b4578fd/webapp/graphite/render/functions.py#L4891
This can lead to issues if the return value of
groupByNodes()
is used as input for another function for which the order is relevant. We have observed a user who's using the output ofgroupByNodes()
as input fordivideSeriesLists()
, which has lead to wrong results once we switched to Metrictank function processing.The text was updated successfully, but these errors were encountered: