cronjob

package
v0.0.0-...-b285d58 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddJob

func AddJob(api string, dr time.Duration, job func() bson.M) (err error)

func GetLatestResult

func GetLatestResult(api string) (res bson.M, err error)

func InitCronjob

func InitCronjob()

func Status2Cond

func Status2Cond(status string) (cond bson.M)

Types

type DescribeAgentData

type DescribeAgentData struct {
	Running     int64   `json:"running" bson:"running"`
	Offline     int64   `json:"offline" bson:"offline"`
	Memory      int64   `json:"memory" bson:"memory,truncate"`
	CPU         float64 `json:"cpu" bson:"cpu"`
	RunningDiff int64   `json:"running_diff" bson:"running_diff"`
	OfflineDiff int64   `json:"offline_diff" bson:"offline_diff"`
	MemoryDiff  int64   `json:"memory_diff" bson:"memory_diff,truncate"`
	CPUDiff     float64 `json:"cpu_diff" bson:"cpu_diff"`
}

Jump to

Keyboard shortcuts

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