service

package
v0.0.0-...-7a62f64 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrDiskNotFound = fmt.Errorf("disk not found")
)
View Source
var ErrNicNotFound = fmt.Errorf("nic not found")

Functions

This section is empty.

Types

type CPU

type CPU interface {
	Description(ctx context.Context) (*cpu.CPU, error)
	Utilization(ctx context.Context) ([]*cpu.Utilization, error)
}

type Host

type Host interface {
	Describe(ctx context.Context) (*host.Host, error)
	Uptime(ctx context.Context) (uint64, error)
	BootTime(ctx context.Context) (uint64, error)
}

type Memory

type Memory interface {
	Description(ctx context.Context) (*memory.Memory, error)
	Utilization(ctx context.Context) (*memory.Utilization, error)
}

type Motherboard

type Motherboard interface {
	DescribeBios(context.Context) (*motherboard.Bios, error)
	DescribeMotherboard(context.Context) (*motherboard.Motherboard, error)
}

type Network

type Network interface {
	ListNics(ctx context.Context) ([]*network.Nic, error)
	ListIpAddresses(ctx context.Context) ([]*network.IpAddress, error)
	DescribeNic(ctx context.Context, name string) (*network.Nic, error)
}

type Reporter

type Reporter interface {
	Heartbeat(ctx context.Context) error
	Register(ctx context.Context) error
	ReportStatus(ctx context.Context, status power.StatusCode) error
	ReportSystemInformation(ctx context.Context) error
}

type Storage

type Storage interface {
	ListDisks(ctx context.Context) ([]*storage.Disk, error)
	DescribeDisk(ctx context.Context, name string) (*storage.Disk, error)
}

type System

type System interface {
	DescribeSystem(ctx context.Context) (*system.System, error)
	DescribeHost(ctx context.Context) (*host.Host, error)
	DescribeMotherboard(ctx context.Context) (*motherboard.Motherboard, error)
	DescribeBios(ctx context.Context) (*motherboard.Bios, error)
	DescribeCpu(ctx context.Context) ([]*cpu.CPU, error)
	DescribeMemory(ctx context.Context) ([]*memory.Memory, error)
}

Jump to

Keyboard shortcuts

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