collector

package
v0.0.0-...-1299c6d Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RocketMQCollector

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

解析数据文件: data.txt --> RocketMQMetricSet RocketMQMetricSet 转换成 prometheus format data 将prometheus format data 输出到标准输出

func NewCollector

func NewCollector() *RocketMQCollector

func (*RocketMQCollector) Collect

func (c *RocketMQCollector) Collect(ch chan<- prometheus.Metric)

func (*RocketMQCollector) Describe

func (c *RocketMQCollector) Describe(ch chan<- *prometheus.Desc)

type RocketMQMetric

type RocketMQMetric struct {
	Group     string
	Count     string
	Version   string
	Type      string
	Model     string
	TPS       string
	DiffTotal string
}

func ParseLine

func ParseLine(line string) *RocketMQMetric

func (*RocketMQMetric) Float64Count

func (m *RocketMQMetric) Float64Count() float64

func (*RocketMQMetric) Float64DiffTotal

func (m *RocketMQMetric) Float64DiffTotal() float64

func (*RocketMQMetric) Float64Tps

func (m *RocketMQMetric) Float64Tps() float64

func (*RocketMQMetric) String

func (m *RocketMQMetric) String() string

type RocketMQMetricSet

type RocketMQMetricSet struct {
	Items []*RocketMQMetric
}

func (*RocketMQMetricSet) Add

func (s *RocketMQMetricSet) Add(item *RocketMQMetric)

Jump to

Keyboard shortcuts

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