modularize monitor, reduce init usage (#81)
* kill process tree using syscall on windows & cleanup (#80) * kill process tree using syscall on windows & cleanup * use job api * add error check for cmd.Start * modularize monitor, reduce init usage * replace slices with sort * update gopsutil & other dependencies
This commit is contained in:
1 parent
0cba96bae1
commit
af41e4d843
23 files changed
+665
-381
No files matched your search
@@ -0,0 +1,11 @@
|
||||
package load
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
psLoad "github.com/shirou/gopsutil/v4/load"
|
||||
)
|
||||
|
||||
func GetState(ctx context.Context) (*psLoad.AvgStat, error) {
|
||||
return psLoad.AvgWithContext(ctx)
|
||||
}
|
||||
Reference in new issue
Block a user