health

package
v1.12.0 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2019 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CheckType

type CheckType string

type HealthCheckResult

type HealthCheckResult struct {
	// A constant representing the type of health check. Values should be uppercase, underscore delimited, ascii letters with no spaces, ([A-Z_]).
	Type CheckType `` /* 168-byte string literal not displayed */
	// Health state of the check.
	State HealthState `json:"state" conjure-docs:"Health state of the check.\n"`
	// Text describing the state of the check which should provide enough information for the check to be actionable when included in an alert.
	Message *string `` /* 168-byte string literal not displayed */
	// Additional redacted information on the nature of the health check.
	Params map[string]interface{} `json:"params" conjure-docs:"Additional redacted information on the nature of the health check.\n"`
}

Metadata describing the status of a service.

func (HealthCheckResult) MarshalJSON

func (o HealthCheckResult) MarshalJSON() ([]byte, error)

func (HealthCheckResult) MarshalYAML

func (o HealthCheckResult) MarshalYAML() (interface{}, error)

func (*HealthCheckResult) UnmarshalJSON

func (o *HealthCheckResult) UnmarshalJSON(data []byte) error

func (*HealthCheckResult) UnmarshalYAML

func (o *HealthCheckResult) UnmarshalYAML(unmarshal func(interface{}) error) error

type HealthState

type HealthState string
const (
	// The service node is fully operational with no issues.
	HealthStateHealthy HealthState = "HEALTHY"
	// The service node is fully operational with no issues; however, it is requesting to defer shutdown or restart. A deferring node should not accept "new" jobs but should allow polling of existing jobs.
	HealthStateDeferring HealthState = "DEFERRING"
	// The service node is no longer serving requests and is ready to be shut down. Nodes in a deferring state are expected to change to a suspended state once they have completed any pending work. A suspended node must also indicate in its readiness probe that it should not receive incoming requests.
	HealthStateSuspended HealthState = "SUSPENDED"
	// The service node is operating in a degraded state, but is capable of automatically recovering. If any of the nodes in the service were to be restarted, it may result in correctness or consistency issues with the service. Ex: When a cassandra node decides it is not up-to-date and needs to repair, the node is operating in a degraded state. Restarting the node prior to the repair being complete might result in the service being unable to correctly respond to requests.
	HealthStateRepairing HealthState = "REPAIRING"
	// The service node is in a state that is trending towards an error. If no corrective action is taken, the health is expected to become an error.
	HealthStateWarning HealthState = "WARNING"
	// The service node is operationally unhealthy.
	HealthStateError HealthState = "ERROR"
	// The service node has entered an unrecoverable state. All nodes of the service should be stopped and no automated attempt to restart the node should be made. Ex: a service fails to migrate to a new schema and is left in an unrecoverable state.
	HealthStateTerminal HealthState = "TERMINAL"
	HealthStateUnknown  HealthState = "UNKNOWN"
)

func (*HealthState) UnmarshalText added in v1.3.5

func (e *HealthState) UnmarshalText(data []byte) error

type HealthStatus

type HealthStatus struct {
	Checks map[CheckType]HealthCheckResult `json:"checks"`
}

func (HealthStatus) MarshalJSON

func (o HealthStatus) MarshalJSON() ([]byte, error)

func (HealthStatus) MarshalYAML

func (o HealthStatus) MarshalYAML() (interface{}, error)

func (*HealthStatus) UnmarshalJSON

func (o *HealthStatus) UnmarshalJSON(data []byte) error

func (*HealthStatus) UnmarshalYAML

func (o *HealthStatus) UnmarshalYAML(unmarshal func(interface{}) error) error

Jump to

Keyboard shortcuts

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