taskinspect

package
v1.3.0-rc.0...-12c9840 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PipelineTaskMaxErrorPerHour = 180
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Inspect

type Inspect struct {
	Inspect     string                   `json:"inspect,omitempty"`
	Events      string                   `json:"events,omitempty"`
	MachineStat *PipelineTaskMachineStat `json:"machineStat,omitempty"`

	// Errors stores from pipeline internal, not callback(like action-agent).
	// For external errors, use taskresult.Result.Errors.
	Errors taskerror.OrderedErrors `json:"errors,omitempty"`

	// Metadata for internal use
	Metadata metadata.Metadata `json:"metadata,omitempty"`
}

func (*Inspect) GetPBMachineStat

func (t *Inspect) GetPBMachineStat() *basepb.PipelineTaskMachineStat

func (*Inspect) IsErrorsExceed

func (t *Inspect) IsErrorsExceed() (bool, *taskerror.Error)

type PipelineTaskMachineHostStat

type PipelineTaskMachineHostStat struct {
	HostIP          string `json:"hostIP,omitempty"`
	Hostname        string `json:"hostname,omitempty"`
	UptimeSec       uint64 `json:"uptimeSec,omitempty"`
	BootTimeSec     uint64 `json:"bootTimeSec,omitempty"`
	OS              string `json:"os,omitempty"`
	Platform        string `json:"platform,omitempty"`
	PlatformVersion string `json:"platformVersion,omitempty"`
	KernelVersion   string `json:"kernelVersion,omitempty"`
	KernelArch      string `json:"kernelArch,omitempty"`
}

type PipelineTaskMachineLoadStat

type PipelineTaskMachineLoadStat struct {
	Load1  float64 `json:"load1,omitempty"`
	Load5  float64 `json:"load5,omitempty"`
	Load15 float64 `json:"load15,omitempty"`
}

type PipelineTaskMachineMemStat

type PipelineTaskMachineMemStat struct {
	Total       uint64  `json:"total,omitempty"`
	Available   uint64  `json:"available,omitempty"`
	Used        uint64  `json:"used,omitempty"`
	Free        uint64  `json:"free,omitempty"`
	UsedPercent float64 `json:"usedPercent,omitempty"`
	Buffers     uint64  `json:"buffers,omitempty"`
	Cached      uint64  `json:"cached,omitempty"`
}

type PipelineTaskMachinePodStat

type PipelineTaskMachinePodStat struct {
	PodIP string `json:"podIP,omitempty"`
}

type PipelineTaskMachineStat

type PipelineTaskMachineStat struct {
	Host PipelineTaskMachineHostStat `json:"host,omitempty"`
	Pod  PipelineTaskMachinePodStat  `json:"pod,omitempty"`
	Load PipelineTaskMachineLoadStat `json:"load,omitempty"`
	Mem  PipelineTaskMachineMemStat  `json:"mem,omitempty"`
	Swap PipelineTaskMachineSwapStat `json:"swap,omitempty"`
}

type PipelineTaskMachineSwapStat

type PipelineTaskMachineSwapStat struct {
	Total       uint64  `json:"total,omitempty"`
	Used        uint64  `json:"used,omitempty"`
	Free        uint64  `json:"free,omitempty"`
	UsedPercent float64 `json:"usedPercent,omitempty"`
}

Jump to

Keyboard shortcuts

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