-
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 netdev collector for darwin #393
Add netdev collector for darwin #393
Conversation
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.
LGTM.
return netDev, nil | ||
} | ||
|
||
func convertFreeBSDCPUTime(counter uint64) string { |
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.
Why is this called CPUTime?
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.
Good question. I've copied it over from the freebsd one. I've changed it to use FormatUint directly.
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.
So this method can be deleted then?
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.
Already did that, looks like the commit is outdated.
e38d1c8
to
f6f1ba1
Compare
Same as for openbsd, this is just slightly adjusted from freebsd variant.
f6f1ba1
to
3c47ef8
Compare
Our company internal Prometheus exporter uses the procfs library and needs to read `/proc/cmdline`. Since `fs.proc.Path` cannot be accessed from outside, add `CmdLine` to procfs to read `/proc/cmdline`. Signed-off-by: Benjamin Drung <benjamin.drung@ionos.com>
Same as for openbsd, this is just slightly adjusted from freebsd
variant.
I'd like to merge all those and only have the bare minimum in platform specific files but for now I think adding it as this is fine. Will help with the refactoring later.