We added a new interface stat to the exporter (and thus telemetry) to show number of firewall rules per interface.
The only thing to discuss is commit 937f27edbdacdf4e64fed4cb08f4e1db7838f1cf where I added a new field to the internal inteface structure. Without it, getting the count of the rules means iterating the TAILQ list.
As telemetry can be called multiple times per minute in practice, I decided to optimize this by creating a dedicated variable. If that is not wanted, I'll simply remove the commit.
This PR can be squashed, as all the commits belong together, but were split due to the above discussion and the fact that two people worked on it.
Fixes #549
We added a new interface stat to the exporter (and thus telemetry) to show number of firewall rules per interface.
The only thing to discuss is commit 937f27edbdacdf4e64fed4cb08f4e1db7838f1cf where I added a new field to the internal inteface structure. Without it, getting the count of the rules means iterating the
TAILQ
list.As telemetry can be called multiple times per minute in practice, I decided to optimize this by creating a dedicated variable. If that is not wanted, I'll simply remove the commit.
This PR can be squashed, as all the commits belong together, but were split due to the above discussion and the fact that two people worked on it.