Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CpuStats ¶
type CpuStats struct {
Total int64 `json:"total_in_bytes,omitempty"`
UserPercent float64 `json:"user_percent,omitempty"`
SysPercent float64 `json:"sys_percent,omitempty"`
IoWaitPercent float64 `json:"io_wait_percent,omitempty"`
IdlePercent float64 `json:"idle_percent,omitempty"`
}
func NewCpuStats ¶
func NewCpuStats(rss *sysstat.RuntimeStatSampler) *CpuStats
type FsStats ¶
func NewFsStats ¶
func NewFsStats(rss *sysstat.RuntimeStatSampler) *FsStats
type GCStats ¶
type GCStats struct {
CgoCalls int64 `json:"calls,omitempty"`
Goroutines int64 `json:"routines,omitempty"`
GcCount int64 `json:"count,omitempty"`
GCCountPercent float64 `json:"count_percent,omitempty"`
GcPauseNS int64 `json:"pause_nanoseconds,omitempty"`
GcPausePercent float64 `json:"pause_percent,omitempty"`
}
func NewGCStats ¶
func NewGCStats(rss *sysstat.RuntimeStatSampler) *GCStats
type MemStats ¶
type MemStats struct {
BaseStats
}
func NewMemStats ¶
func NewMemStats(rss *sysstat.RuntimeStatSampler) *MemStats
type NetStats ¶
type NetStats struct {
InPerSec int64 `json:"in_pre_second,omitempty"`
OutPerSec int64 `json:"out_pre_second,omitempty"`
Connect int64 `json:"connect,omitempty"`
}
func NewNetStats ¶
func NewNetStats(rss *sysstat.RuntimeStatSampler) *NetStats
type ServerStats ¶
type ServerStats struct {
Status int64 `json:"status"`
Ip string `json:"ip"`
Labels []metrics.LabelPair `json:"labels"`
Mem *MemStats `json:"mem,omitempty"`
Swap *SwapStats `json:"swap,omitempty"`
Fs *FsStats `json:"fs,omitempty"`
Cpu *CpuStats `json:"cpu,omitempty"`
Net *NetStats `json:"net,omitempty"`
GC *GCStats `json:"gc,omitempty"`
Err string `json:"err,omitempty"`
ActiveConn int `json:"active_conn,omitempty"`
PartitionInfos []*entity.PartitionInfo `json:"partition_infos,omitempty"`
}
func NewErrServerStatus ¶
func NewErrServerStatus(ip string, err error) *ServerStats
func NewServerStats ¶
func NewServerStats() *ServerStats
type SwapStats ¶
type SwapStats struct {
BaseStats
}
func NewSwapStats ¶
func NewSwapStats(rss *sysstat.RuntimeStatSampler) *SwapStats
Click to show internal directories.
Click to hide internal directories.