monitor_health

package
v6.2.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2018 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(base mb.BaseMetricSet) (mb.MetricSet, error)

Types

type Health

type Health struct {
	HealthServices []HealthServices `json:"health_services"`
}

type HealthRequest

type HealthRequest struct {
	Status string `json:"status"`
	Output Output `json:"output"`
}

type HealthServices

type HealthServices struct {
	Mons []Mon `json:"mons"`
}

type MetricSet

type MetricSet struct {
	mb.BaseMetricSet
	*helper.HTTP
}

func (*MetricSet) Fetch

func (m *MetricSet) Fetch() ([]common.MapStr, error)

type Mon

type Mon struct {
	LastUpdated  Tick       `json:"last_updated"`
	Name         string     `json:"name"`
	AvailPercent int64      `json:"avail_percent"`
	KbTotal      int64      `json:"kb_total"`
	KbAvail      int64      `json:"kb_avail"`
	Health       string     `json:"health"`
	KbUsed       int64      `json:"kb_used"`
	StoreStats   StoreStats `json:"store_stats"`
}

type Output

type Output struct {
	OverallStatus string    `json:"overall_status"`
	Timechecks    Timecheck `json:"timechecks"`
	Health        Health    `json:"health"`
}

type StoreStats

type StoreStats struct {
	BytesTotal  int64  `json:"bytes_total"`
	BytesLog    int64  `json:"bytes_log"`
	LastUpdated string `json:"last_updated"`
	BytesMisc   int64  `json:"bytes_misc"`
	BytesSSt    int64  `json:"bytes_sst"`
}

type Tick

type Tick struct {
	time.Time
}

func (*Tick) MarshalJSON

func (t *Tick) MarshalJSON() ([]byte, error)

func (*Tick) UnmarshalJSON

func (t *Tick) UnmarshalJSON(b []byte) (err error)

type Timecheck

type Timecheck struct {
	RoundStatus string `json:"round_status"`
	Epoch       int64  `json:"epoch"`
	Round       int64  `json:"round"`
}

Jump to

Keyboard shortcuts

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