Documentation
¶
Index ¶
- Constants
- Variables
- func GetMetricsZipFile(startTime time.Time, endTime time.Time) (string, error)
- func InitMetricsDumpJob(ctx context.Context)
- func RegisterSyncCache()
- func RemoveRuleStatus(ruleID string)
- func SetRuleCPUUsageGauge(ruleID string, value int)
- func SetRuleStatus(ruleID string, value int)
- func SetRuleStatusCountGauge(isRunning bool, count int)
- type MetricsDumpManager
Constants ¶
View Source
const ( LblType = "type" LblStatusType = "status" LblRuleIDType = "rule" LblOpIDType = "op" LblIOType = "io" LBlRuleRunning = "running" LblRuleStop = "stop" LblSourceIO = "source" LblSinkIO = "sink" )
View Source
const OpenMetricsEOF = "# EOF\n"
Variables ¶
View Source
var ( RuleStatusCountGauge = prometheus.NewGaugeVec(prometheus.GaugeOpts{ Namespace: "kuiper", Subsystem: "rule", Name: "count", Help: "gauge of rule status count", }, []string{LblStatusType}) RuleStatusGauge = prometheus.NewGaugeVec(prometheus.GaugeOpts{ Namespace: "kuiper", Subsystem: "rule", Name: "status", Help: "gauge of rule status", }, []string{LblRuleIDType}) RuleCPUUsageGauge = prometheus.NewGaugeVec(prometheus.GaugeOpts{ Namespace: "kuiper", Subsystem: "rule", Name: "cpu_ms", Help: "gauge of rule CPU usage", }, []string{LblRuleIDType}) )
View Source
var ( SyncCacheHist = prometheus.NewHistogramVec(prometheus.HistogramOpts{ Namespace: "kuiper", Subsystem: "sync_cache", Name: "duration", Buckets: prometheus.ExponentialBuckets(10, 2, 20), Help: "hist of sync cache", }, []string{LblType, LblRuleIDType, LblOpIDType}) SyncCacheCounter = prometheus.NewCounterVec(prometheus.CounterOpts{ Namespace: "kuiper", Subsystem: "sync_cache", Name: "counter", Help: "counter of sync cache", }, []string{LblType, LblRuleIDType, LblOpIDType}) )
Functions ¶
func GetMetricsZipFile ¶
func InitMetricsDumpJob ¶
func RegisterSyncCache ¶
func RegisterSyncCache()
func RemoveRuleStatus ¶
func RemoveRuleStatus(ruleID string)
func SetRuleCPUUsageGauge ¶
func SetRuleStatus ¶
func SetRuleStatusCountGauge ¶
Types ¶
type MetricsDumpManager ¶
type MetricsDumpManager struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.