Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var NetworkCheckerInstance = &NetworkChecker{}
View Source
var VMCheckerInstance = &VMChecker{}
Functions ¶
func IsHealthy ¶
func IsHealthy(checks []HealthCheck) bool
Types ¶
type Checker ¶
type Checker interface {
Name() string
Run(ctx context.Context, data *CheckData) []HealthCheck
}
type HealthCheck ¶
type HealthCheck struct {
Name string `json:"name"`
OK bool `json:"ok"`
Message string `json:"message,omitempty"`
Evidence map[string]interface{} `json:"evidence,omitempty"`
}
func Run ¶
func Run(ctx context.Context, workloadType gridtypes.WorkloadType, data *CheckData) []HealthCheck
type NetworkChecker ¶
type NetworkChecker struct {
// contains filtered or unexported fields
}
func (*NetworkChecker) Name ¶
func (nc *NetworkChecker) Name() string
func (*NetworkChecker) Run ¶
func (nc *NetworkChecker) Run(ctx context.Context, data *CheckData) []HealthCheck
type SystemChecker ¶
type SystemChecker struct {
// contains filtered or unexported fields
}
func NewSystemChecker ¶
func NewSystemChecker(command string) *SystemChecker
func (*SystemChecker) Name ¶
func (sc *SystemChecker) Name() string
func (*SystemChecker) Run ¶
func (sc *SystemChecker) Run(ctx context.Context, data *CheckData) []HealthCheck
Click to show internal directories.
Click to hide internal directories.