Documentation ¶
Index ¶
Constants ¶
View Source
const ( LabelNodeStart = "NodeStart" LabelStartTheWorld = "StartTheWorld" LabelStopTheWorld = "StopTheWorld" LabelTaskExec = "TaskExec" LabelLeaderChange = "LeaderChange" LabelLeaderChangeFailed = "LeaderChangeFailed" LabelWorkerNodeOffline = "WorkerNodeOffline" LabelRegistryOnline = "RegistryOnline" LabelRegistryOffline = "RegistryOffline" )
Variables ¶
This section is empty.
Functions ¶
func GetAllCountInfo ¶
GetAllCountInfo get all counter's count for map[string]int64
Types ¶
type Metrics ¶
type Metrics interface { GetStandardCounter(label string) Counter Inc(label string) Dec(label string) Add(label string, value int64) }
func NewMetrics ¶
func NewMetrics() Metrics
type StandardMetrics ¶
type StandardMetrics struct {
// contains filtered or unexported fields
}
func (*StandardMetrics) Add ¶
func (m *StandardMetrics) Add(label string, value int64)
Add increments the counter by the given value.
func (*StandardMetrics) Dec ¶
func (m *StandardMetrics) Dec(label string)
Dec decrements the counter by 1.
func (*StandardMetrics) GetStandardCounter ¶
func (m *StandardMetrics) GetStandardCounter(label string) Counter
GetCounter get Counter by key
func (*StandardMetrics) Inc ¶
func (m *StandardMetrics) Inc(label string)
Inc increments the counter by 1.
Click to show internal directories.
Click to hide internal directories.