diagnostics

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Modules = []string{
	"storage",
	"node",
	"identityd",
	"vmd",
	"flist",
	"network",
	"container",
	"provision",
	"gateway",
	"qsfsd",
}

Modules is all the registered modules on zbus

Functions

This section is empty.

Types

type Diagnostics

type Diagnostics struct {
	// SystemStatusOk is the overall system status
	SystemStatusOk bool `json:"system_status_ok"`
	// ZosModules is a list of modules with their objects and workers
	ZosModules map[string]ModuleStatus `json:"modules"`
	// Healthy is the state of the node health check
	Healthy bool `json:"healthy"`
}

Diagnostics show the health of zbus modules

type DiagnosticsManager

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

func NewDiagnosticsManager

func NewDiagnosticsManager(
	msgBrokerCon string,
	busClient zbus.Client,
) (*DiagnosticsManager, error)

func (*DiagnosticsManager) GetSystemDiagnostics

func (m *DiagnosticsManager) GetSystemDiagnostics(ctx context.Context) (Diagnostics, error)

type ModuleStatus

type ModuleStatus struct {
	// Status holds the status of the module
	Status zbus.Status `json:"status,omitempty"`
	// Err contains any error related to the module
	Err error `json:"error,omitempty"`
}

ModuleStatus represents the status of a module or shows if error

Jump to

Keyboard shortcuts

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