repository

package
v1.1.45 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Alert

type Alert interface {
	// SaveAlarm 保存告警
	SaveAlarm(ctx context.Context, alarm *bo.Alarm) error
	// PushAlarm 推送告警
	PushAlarm(ctx context.Context, alarm *bo.Alarm) error
}

Alert .

type CacheRepo

type CacheRepo interface {
	// Cacher 获取缓存实现
	Cacher() cache.ICacher
}

CacheRepo 换成统一repo

type Heartbeat added in v1.1.0

type Heartbeat interface {
	Heartbeat(ctx context.Context, in *api.HeartbeatRequest) error
}

Heartbeat .

type Metric

type Metric interface {
	// GetMetrics 获取指标列表
	GetMetrics(ctx context.Context, datasourceInfo *bo.GetMetricsParams) ([]*bo.MetricDetail, error)

	// Query 查询QL数据
	Query(ctx context.Context, req *bo.QueryQLParams) ([]*datasource.QueryResponse, error)

	// PushMetric 推送
	PushMetric(ctx context.Context, req *bo.PushMetricParams) error
}

Metric .

type Strategy

type Strategy interface {
	// Save 保存策略
	Save(ctx context.Context, strategies []bo.IStrategy) error

	// Eval 策略评估
	Eval(ctx context.Context, strategy bo.IStrategy) (*bo.Alarm, error)
}

Strategy .

Jump to

Keyboard shortcuts

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