From 9f7d756b3b4a140309e87adb06de001ef82029d8 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Sat, 11 Mar 2023 12:57:26 +0100 Subject: ... --- overlays/cake-prometheus-exporter/cake-prometheus-exporter.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'overlays/cake-prometheus-exporter') diff --git a/overlays/cake-prometheus-exporter/cake-prometheus-exporter.py b/overlays/cake-prometheus-exporter/cake-prometheus-exporter.py index 06e03469..56820a56 100644 --- a/overlays/cake-prometheus-exporter/cake-prometheus-exporter.py +++ b/overlays/cake-prometheus-exporter/cake-prometheus-exporter.py @@ -87,8 +87,8 @@ class CAKEMetrics: for packet_counter in ['packets', 'overlimits', 'requeues', 'drops']: metrics += _format_prom_metrics(f'cake_{packet_counter}', 'counter', [({'dev': dev}, self.attrs[dev][packet_counter]) for dev in self.attrs]) - metrics += _format_prom_metrics('cake_tin_bytes', 'counter', [({'dev': dev, 'tin': tin}, self.attrs[dev]['tins'][tin]['bytes']) for tin in self.attrs[dev]['tins'] for dev in self.attrs]) - metrics += _format_prom_metrics('cake_tin_packets', 'counter', [({'dev': dev, 'tin': tin}, self.attrs[dev]['tins'][tin]['packets']) for tin in self.attrs[dev]['tins'] for dev in self.attrs]) + metrics += _format_prom_metrics('cake_tin_bytes', 'counter', [({'dev': dev, 'tin': tin}, self.attrs[dev]['tins'][tin]['bytes'] for dev in self.attrs) for tin in self.attrs[dev]['tins']]) + metrics += _format_prom_metrics('cake_tin_packets', 'counter', [({'dev': dev, 'tin': tin}, self.attrs[dev]['tins'][tin]['packets']) for dev in self.attrs for tin in self.attrs[dev]['tins']]) return metrics.encode('utf-8') -- cgit v1.2.3