Sebastiaan van Stijn
|
ce332e1952
|
executor/resource: stub out NewSysSampler on Windows
Commit 509cfa3916 introduced the SysSampler,
which measures resource consumption. However, for this it depends on
prometheus' procfs. That package does not have build-tags but is a Linux-only
implementation, which (by default) attempts to access `/proc`;
https://github.com/prometheus/procfs/blob/v0.9.0/fs.go#L26-L33
https://github.com/prometheus/procfs/blob/v0.9.0/internal/fs/fs.go#L23-L24
This patch splits the implementation of "resource" into platform-specific
files, and stubs out the NewSysSampler() on non-Linux platforms.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
|
2023-07-20 14:28:53 +02:00 |
|