syslib

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 7, 2016 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLoadAverage

func GetLoadAverage() []byte

func GetMemory

func GetMemory() []byte

func GetProcStatusByPid

func GetProcStatusByPid(pid int32) string

*

@return {"is_running":true,"memory_percent":2.2123966,"cpu_percent":0.999388968588172}

func GetReadToRunJobs

func GetReadToRunJobs(size int) []byte

get entries

func RmTaskById

func RmTaskById(taskId int) string

func RunTask

func RunTask(taskId int) string

*

return AddJob error: %s OR AddJob %s success

Types

type ProcessState

type ProcessState struct {
	Pid           int32   `json:"pid"`
	IsRunning     bool    `json:"is_running"`
	MemoryPercent float32 `json:"memory_percent"`
	CpuPercent    float64 `json:"cpu_percent"`
}

type RetRunJob

type RetRunJob struct {
	Tid    int    `json:"tid"`
	Status int    `json:"status"`
	Name   string `json:"name"`
	Pid    int    `json:"pid"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL