ironcore-dev / dpservice

DPDK based fast Dataplane / L3 router / SDN enabler, installable on compute nodes / SmartNICs
Apache License 2.0
7 stars 1 forks source link

Add firewall telemetry - rule count #571

Closed PlagueCZ closed 3 months ago

PlagueCZ commented 3 months ago

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.