rsd

package
v0.0.0-...-8d16fc4 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterExporter

type ClusterExporter struct {
	sync.Mutex

	RedisEndpoint string
	ClusterNodes  []*ClusterNode
}

func NewClusterExporter

func NewClusterExporter(addr string) (*ClusterExporter, error)

func (*ClusterExporter) DiscoveryCluster

func (ce *ClusterExporter) DiscoveryCluster() error

DiscoveryCluster discovery all nodes on the cluster.

type ClusterNode

type ClusterNode struct {
	Exporter    *Exporter
	NodeID      string
	Addr        string
	Flags       string
	MasterID    string
	PingSent    string
	PongRecv    string
	ConfigEpoch string
	LinkState   string
	Slots       string
}

type Exporter

type Exporter struct {
	// contains filtered or unexported fields
}

Exporter implements the prometheus.Exporter interface, and exports Redis metrics.

func NewRedisExporter

func NewRedisExporter(redisURI string) (*Exporter, error)

NewRedisExporter returns a new exporter of Redis metrics.

type SDConfig

type SDConfig struct {
	Targets []string          `json:"targets"`
	Labels  map[string]string `json:"labels"`
}

type SDConfigs

type SDConfigs []SDConfig

type Service

type Service struct {
	Type   string            `json:"type"`
	Job    string            `json:"job"`
	URL    string            `json:"url"`
	Labels map[string]string `json:"labels"`
}

type Services

type Services struct {
	Services []Service `json:"services"`
}

Jump to

Keyboard shortcuts

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