On 17/12/2020 17:57, Raghu Udiyar wrote:
Hello

When using aggregations such as `max(metric1) by (lable1)`, all the other labels are stripped. Is it possible to preserve the labels, akin to *selecting* the `max` series.

This is more of a filter, not an aggregation.

I'm not quite sure I understand what you are wanting.

Normal aggregations (sum, max, avg, etc.) will have to remove at least one label, otherwise nothing will be being aggregated (the output will just be the same as the input).

Are you maybe wanting the topk operator?

Could you give an example of what you are trying to achieve so we might be able to assist better?

Thanks

--
You received this message because you are subscribed to the Google Groups 
"Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/prometheus-users/0cf3dbed-bddd-ffaf-dd93-8baaee2c8424%40Jahingo.com.

Reply via email to