api

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 25, 2020 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Alert

type Alert struct {
	Level   string    `json:"level,omitempty"`
	Since   time.Time `json:"since,omitempty"`
	Message string    `json:"message,omitempty"`
}

type Canarydata

type Canarydata struct {
	ServerName string `json:"server_name,omitempty"`
	Checks     []Chek `json:"checks,omitempty"`
}

type Chek

type Chek struct {
	Key           string       `json:"key,omitempty"`
	Type          string       `json:"type,omitempty"`
	Name          string       `json:"name,omitempty"`
	Description   string       `json:"description,omitempty"`
	Uptime        string       `json:"uptime,omitempty"`
	Latency       string       `json:"latency,omitempty"`
	CheckStatuses []ChekStatus `json:"checkStatuses,omitempty"`
	// contains filtered or unexported fields
}

type ChekConf

type ChekConf struct {
	Server          string
	Port            int
	Query           string
	QueryType       string
	Minrecords      string
	ExactReply      []string
	Timeout         int
	ThresholdMillis int
}

type ChekStatus

type ChekStatus struct {
	Status   bool
	Invalid  bool
	Time     string
	Duration int
	Message  string
}

type Cluster

type Cluster struct {
	Name         string     `json:"name,omitempty"`
	Properties   []Property `json:"properties,omitempty"`
	CanaryChecks []Chek     `json:"canary_checks,omitempty"`
	Nodes        []Node     `json:"nodes,omitempty"`
	Alerts       []Alert    `json:"alerts,omitempty"`
}

type ClusterConfiguration

type ClusterConfiguration struct {
	CanaryChecker string `yaml:"canaryChecker,omitempty"`
	Prometheus    string `yaml:"prometheus,omitempty"`
	AlertManager  string `yaml:"alertmanager,omitempty"`
	Kubeconfig    string `yaml:"kubeconfig,omitempty"`
}

type Node

type Node struct {
	Name   string  `json:"name,omitempty"`
	IP     string  `json:"ip,omitempty"`
	Alerts []Alert `json:"alerts,omitempty"`
}

type Property

type Property struct {
	Name   string  `json:"name,omitempty"`
	Value  string  `json:"label,omitempty"`
	Type   string  `json:"type,omitempty"`
	Icon   string  `json:"icon,omitempty"`
	Alerts []Alert `json:"alerts,omitempty"`
}

Jump to

Keyboard shortcuts

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