client

package
v0.0.0-...-9b60763 Latest Latest
Warning

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

Go to latest
Published: Aug 13, 2021 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MetricsOutputSummaryKey = "SUMMARY"
)

Variables

View Source
var (
	ConfigCheckedAt time.Time
)

Functions

func PBToMetrics

func PBToMetrics(resp *pb.GetMetricsResponse) map[string]*types.ClusterMetric

Types

type Client

type Client struct {
	ServerAddress      string
	MetricFormatFile   string
	HeaderTemplateFile string
	OutputTemplateFile string
	ShowDevices        bool
	ShowAsTop          bool
	// contains filtered or unexported fields
}

func NewClient

func NewClient(serverAddr, metricFormatFile, headerTmplFile, outputTmplFile string) *Client

func (*Client) GetMetrics

func (c *Client) GetMetrics() (map[string]*types.ClusterMetric, error)

func (*Client) Start

func (c *Client) Start() error

type MetricFormat

type MetricFormat struct {
	Name      string `yaml:"name"`
	ValueType string `yaml:"value_type"`
	Shorthand string `yaml:"shorthand"`
}

Jump to

Keyboard shortcuts

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