tetragon icon indicating copy to clipboard operation
tetragon copied to clipboard

Add node_name label to metrics

Open lambdanis opened this issue 5 months ago • 0 comments

Currently metrics exposed by Tetragon don't have a label with the node name. node label is added by a relabeling in the default ServiceMonitor. This works well enough, however:

  • In deployments not using the default ServiceMonitor, users have to manually configure scrape config to add such relabeling.
  • In some deployments (non-k8s in particular) node name might be not available to Prometheus at the scrape time.
  • node label on metrics might end up being different than node_name field in JSON events.
  • It's always nice to have metrics labels matching events fields.

So I'm suggesting to add node_name label to all metrics exposed by Tetragon - it should be retrieved in the same way as node_name in events.

lambdanis avatar Mar 12 '24 02:03 lambdanis