gops

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2025 License: MIT Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CPUTracker

type CPUTracker struct {
	// contains filtered or unexported fields
}

type GopsUtil

type GopsUtil struct{}

func NewGopsUtil

func NewGopsUtil() *GopsUtil

func (*GopsUtil) GetAllMetrics

func (self *GopsUtil) GetAllMetrics(procSortBy ProcSortBy, procLimit int, enableProcessCPU bool) (*models.SystemMetrics, error)

func (*GopsUtil) GetAllMetricsWithCursors

func (self *GopsUtil) GetAllMetricsWithCursors(procSortBy ProcSortBy, procLimit int, enableProcessCPU bool, cpuCursor string, procCursor string) (*models.SystemMetrics, error)

func (*GopsUtil) GetCPUInfo

func (self *GopsUtil) GetCPUInfo() (*models.CPUInfo, error)

func (*GopsUtil) GetCPUInfoWithCursor

func (self *GopsUtil) GetCPUInfoWithCursor(cursor string) (*models.CPUInfo, error)

func (*GopsUtil) GetDiskInfo

func (self *GopsUtil) GetDiskInfo() ([]*models.DiskInfo, error)

func (*GopsUtil) GetDiskMounts

func (self *GopsUtil) GetDiskMounts() ([]*models.DiskMountInfo, error)

func (*GopsUtil) GetGPUInfo

func (self *GopsUtil) GetGPUInfo() (*models.GPUInfo, error)

func (*GopsUtil) GetGPUInfoWithTemp

func (self *GopsUtil) GetGPUInfoWithTemp(pciIds []string) (*models.GPUInfo, error)

func (*GopsUtil) GetGPUTemp

func (self *GopsUtil) GetGPUTemp(pciId string) (*models.GPUTempInfo, error)

func (*GopsUtil) GetMemoryInfo

func (self *GopsUtil) GetMemoryInfo() (*models.MemoryInfo, error)

func (*GopsUtil) GetMeta

func (self *GopsUtil) GetMeta(modules []string, params MetaParams) (*models.MetaInfo, error)

func (*GopsUtil) GetModules

func (self *GopsUtil) GetModules() (*models.ModulesInfo, error)

func (*GopsUtil) GetNetworkInfo

func (self *GopsUtil) GetNetworkInfo() ([]*models.NetworkInfo, error)

func (*GopsUtil) GetProcesses

func (self *GopsUtil) GetProcesses(sortBy ProcSortBy, limit int, enableCPU bool) (*models.ProcessListResponse, error)

func (*GopsUtil) GetProcessesWithCursor

func (self *GopsUtil) GetProcessesWithCursor(sortBy ProcSortBy, limit int, enableCPU bool, cursor string) (*models.ProcessListResponse, error)

func (*GopsUtil) GetSystemHardware

func (self *GopsUtil) GetSystemHardware() (*models.SystemHardware, error)

func (*GopsUtil) GetSystemInfo

func (self *GopsUtil) GetSystemInfo() (*models.SystemInfo, error)

type MetaParams

type MetaParams struct {
	SortBy     ProcSortBy
	ProcLimit  int
	EnableCPU  bool
	GPUPciIds  []string
	CPUCursor  string
	ProcCursor string
}

type ProcSortBy

type ProcSortBy string
const (
	SortByCPU    ProcSortBy = "cpu"
	SortByMemory ProcSortBy = "memory"
	SortByName   ProcSortBy = "name"
	SortByPID    ProcSortBy = "pid"
)

func (ProcSortBy) Schema

func (u ProcSortBy) Schema(r huma.Registry) *huma.Schema

Register enum in OpenAPI specification https://github.com/danielgtaylor/huma/issues/621

Jump to

Keyboard shortcuts

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