Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrUserNotFound is user not found. ErrUserNotFound = errors.NotFound(v1.ErrorReason_USER_NOT_FOUND.String(), "user not found") )
View Source
var ProviderSetBiz = wire.NewSet( NewGreeterUsecase, NewMetricBiz, NewStrategyBiz, NewAlertBiz, )
ProviderSetBiz is biz providers.
Functions ¶
This section is empty.
Types ¶
type AlertBiz ¶
type AlertBiz struct {
// contains filtered or unexported fields
}
AlertBiz .
func NewAlertBiz ¶
func NewAlertBiz(alertRepository repository.Alert) *AlertBiz
NewAlertBiz new AlertBiz
type GreeterRepo ¶
type GreeterRepo interface { Save(context.Context, *Greeter) (*Greeter, error) Update(context.Context, *Greeter) (*Greeter, error) FindByID(context.Context, int64) (*Greeter, error) ListByHello(context.Context, string) ([]*Greeter, error) ListAll(context.Context) ([]*Greeter, error) }
GreeterRepo is a Greater repo.
type GreeterUsecase ¶
type GreeterUsecase struct {
// contains filtered or unexported fields
}
GreeterUsecase is a Greeter usecase.
func NewGreeterUsecase ¶
func NewGreeterUsecase(repo GreeterRepo, cacheRepo repository.CacheRepo) *GreeterUsecase
NewGreeterUsecase new a Greeter usecase.
func (*GreeterUsecase) CreateGreeter ¶
CreateGreeter creates a Greeter, and returns the new Greeter.
type MetricBiz ¶
type MetricBiz struct {
// contains filtered or unexported fields
}
MetricBiz .
func NewMetricBiz ¶
func NewMetricBiz(metricRepository repository.Metric) *MetricBiz
NewMetricBiz new MetricBiz
func (*MetricBiz) PushMetric ¶
func (b *MetricBiz) PushMetric(req *bo.PushMetricParams) error
PushMetric 推送数据
func (*MetricBiz) Query ¶
func (b *MetricBiz) Query(ctx context.Context, req *bo.QueryQLParams) ([]*datasource.QueryResponse, error)
Query 查询数据
func (*MetricBiz) SyncMetrics ¶
func (b *MetricBiz) SyncMetrics(ctx context.Context, datasourceInfo *bo.GetMetricsParams) ([]*bo.MetricDetail, error)
SyncMetrics 同步数据源元数据
type StrategyBiz ¶
type StrategyBiz struct {
// contains filtered or unexported fields
}
StrategyBiz .
func NewStrategyBiz ¶
func NewStrategyBiz(strategyRepository repository.Strategy) *StrategyBiz
NewStrategyBiz new StrategyBiz
func (*StrategyBiz) SaveStrategy ¶
SaveStrategy 保存策略信息
Click to show internal directories.
Click to hide internal directories.