-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add collector for Linux kTLS statss #2950
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Felix Aronsson <[email protected]>
Signed-off-by: Felix Aronsson <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add the new collector to the README.
} | ||
|
||
ktlsCurrTxSwDesc := prometheus.NewDesc( | ||
prometheus.BuildFQName(namespace, "ktls", "tls_curr_tx_sw"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please make this a const:
prometheus.BuildFQName(namespace, "ktls", "tls_curr_tx_sw"), | |
const ktlsSubsystem = "ktls" | |
... | |
prometheus.BuildFQName(namespace, ktlsSubsystem, "tls_curr_tx_sw"), |
nil, nil, | ||
) | ||
ktlsCurrRxSwDesc := prometheus.NewDesc( | ||
prometheus.BuildFQName(namespace, "ktls", "tls_curr_rx_sw"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These metric names are a bit confusing compared to the help text.
Maybe something like this? We try and make metric names more human friendly.
prometheus.BuildFQName(namespace, "ktls", "tls_curr_rx_sw"), | |
prometheus.BuildFQName(namespace, "ktls", "receive_sessions"), |
nil, nil, | ||
) | ||
ktlsRxDeviceDesc := prometheus.NewDesc( | ||
prometheus.BuildFQName(namespace, "ktls", "tls_rx_device_total"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what "device" is, this appears to be about sessions.
prometheus.BuildFQName(namespace, "ktls", "tls_rx_device_total"), | |
prometheus.BuildFQName(namespace, "ktls", "tls_rx_sessions_total"), |
Updating
github.com/prometheus/procfs
to v0.13.0, and adding a collector for exporting Linux kTLS statistics. (added toprometheus/procfs
in prometheus/procfs#579). The metric names and their descriptions are all based on https://docs.kernel.org/networking/tls.html#statistics.Fixes #2290