osmain

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2021 License: Apache-2.0, Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const MaxEntries = 15

Number of Pids(in future cgroups etc) to display for top-N metrics

Variables

This section is empty.

Functions

This section is empty.

Types

type DisplayWidgets

type DisplayWidgets struct {
	Summary           *termui.Par
	ProcessesByCPU    *termui.List
	ProcessesByMemory *termui.List
	ProcessesByIO     *termui.List
	DiskIOUsage       *termui.List
	FileSystemUsage   *termui.List
	InterfaceUsage    *termui.List
	CgroupsCPU        *termui.List
	CgroupsMem        *termui.List
	Problems          *termui.List
}

DisplayWidgets represents various variables used for display Perhaps this belongs to main package

type Stats

type Stats struct {
	CPUStat     *cpustat.CPUStat
	MemStat     *memstat.MemStat
	ProcessStat *pidstat.ProcessStat
	Problems    []string // various problems spotted
	OsSpecific  interface{}
}

Stats represents all statistics collected and printed by osmain

func Register

func Register(m *metrics.MetricContext, step time.Duration) *Stats

Register starts metrics collection for all available metrics

func (*Stats) Print

func (stats *Stats) Print(batchmode bool, layout *DisplayWidgets)

Print inspects and prints various metrics collected started by Register

Jump to

Keyboard shortcuts

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