Table with Sum of Last values grouped by kubernetes.pod.uuid

Ive got a counter on each running kubernetes pod:

{ name: foo, counter: 5, pod.uuid: 111, timestamp: 1 } and { name: foo, counter: 10, pod.uuid: 111, timestamp: 2 }

{ name: foo, counter: 5, pod.uuid: 222, timestamp: 1 }
{ name: bar, counter: 5, pod.uuid: 222, timestamp: 1 }.

I want to have a table with:

foo |. 15
bar |. 5

This boils down to retrieving the last-value grouped-by pod.uuid and name. These values, then need to be summed grouped by name.

I tried with TSVB, but this seems to be too limited to support this.

Could someone help me with suggesting the right approach? I feel that this counter example shouldnt be the hardest thing to visualize but Im struggling :slight_smile:

I think you might need to transform the data first and then do the sum - Transform overview | Elasticsearch Guide [7.15] | Elastic

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.