strategy

package
v0.0.23 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Strategy_CreateStrategy_FullMethodName            = "/api.server.prom.strategy.Strategy/CreateStrategy"
	Strategy_UpdateStrategy_FullMethodName            = "/api.server.prom.strategy.Strategy/UpdateStrategy"
	Strategy_BatchUpdateStrategyStatus_FullMethodName = "/api.server.prom.strategy.Strategy/BatchUpdateStrategyStatus"
	Strategy_DeleteStrategy_FullMethodName            = "/api.server.prom.strategy.Strategy/DeleteStrategy"
	Strategy_BatchDeleteStrategy_FullMethodName       = "/api.server.prom.strategy.Strategy/BatchDeleteStrategy"
	Strategy_GetStrategy_FullMethodName               = "/api.server.prom.strategy.Strategy/GetStrategy"
	Strategy_ListStrategy_FullMethodName              = "/api.server.prom.strategy.Strategy/ListStrategy"
	Strategy_SelectStrategy_FullMethodName            = "/api.server.prom.strategy.Strategy/SelectStrategy"
	Strategy_ExportStrategy_FullMethodName            = "/api.server.prom.strategy.Strategy/ExportStrategy"
	Strategy_GetStrategyNotifyObject_FullMethodName   = "/api.server.prom.strategy.Strategy/GetStrategyNotifyObject"
	Strategy_BindStrategyNotifyObject_FullMethodName  = "/api.server.prom.strategy.Strategy/BindStrategyNotifyObject"
	Strategy_TestNotifyTemplate_FullMethodName        = "/api.server.prom.strategy.Strategy/TestNotifyTemplate"
)
View Source
const OperationStrategyBatchDeleteStrategy = "/api.server.prom.strategy.Strategy/BatchDeleteStrategy"
View Source
const OperationStrategyBatchUpdateStrategyStatus = "/api.server.prom.strategy.Strategy/BatchUpdateStrategyStatus"
View Source
const OperationStrategyBindStrategyNotifyObject = "/api.server.prom.strategy.Strategy/BindStrategyNotifyObject"
View Source
const OperationStrategyCreateStrategy = "/api.server.prom.strategy.Strategy/CreateStrategy"
View Source
const OperationStrategyDeleteStrategy = "/api.server.prom.strategy.Strategy/DeleteStrategy"
View Source
const OperationStrategyExportStrategy = "/api.server.prom.strategy.Strategy/ExportStrategy"
View Source
const OperationStrategyGetStrategy = "/api.server.prom.strategy.Strategy/GetStrategy"
View Source
const OperationStrategyGetStrategyNotifyObject = "/api.server.prom.strategy.Strategy/GetStrategyNotifyObject"
View Source
const OperationStrategyListStrategy = "/api.server.prom.strategy.Strategy/ListStrategy"
View Source
const OperationStrategySelectStrategy = "/api.server.prom.strategy.Strategy/SelectStrategy"
View Source
const OperationStrategyTestNotifyTemplate = "/api.server.prom.strategy.Strategy/TestNotifyTemplate"
View Source
const OperationStrategyUpdateStrategy = "/api.server.prom.strategy.Strategy/UpdateStrategy"

Variables

View Source
var File_server_prom_strategy_strategy_proto protoreflect.FileDescriptor
View Source
var Strategy_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.server.prom.strategy.Strategy",
	HandlerType: (*StrategyServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateStrategy",
			Handler:    _Strategy_CreateStrategy_Handler,
		},
		{
			MethodName: "UpdateStrategy",
			Handler:    _Strategy_UpdateStrategy_Handler,
		},
		{
			MethodName: "BatchUpdateStrategyStatus",
			Handler:    _Strategy_BatchUpdateStrategyStatus_Handler,
		},
		{
			MethodName: "DeleteStrategy",
			Handler:    _Strategy_DeleteStrategy_Handler,
		},
		{
			MethodName: "BatchDeleteStrategy",
			Handler:    _Strategy_BatchDeleteStrategy_Handler,
		},
		{
			MethodName: "GetStrategy",
			Handler:    _Strategy_GetStrategy_Handler,
		},
		{
			MethodName: "ListStrategy",
			Handler:    _Strategy_ListStrategy_Handler,
		},
		{
			MethodName: "SelectStrategy",
			Handler:    _Strategy_SelectStrategy_Handler,
		},
		{
			MethodName: "ExportStrategy",
			Handler:    _Strategy_ExportStrategy_Handler,
		},
		{
			MethodName: "GetStrategyNotifyObject",
			Handler:    _Strategy_GetStrategyNotifyObject_Handler,
		},
		{
			MethodName: "BindStrategyNotifyObject",
			Handler:    _Strategy_BindStrategyNotifyObject_Handler,
		},
		{
			MethodName: "TestNotifyTemplate",
			Handler:    _Strategy_TestNotifyTemplate_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "server/prom/strategy/strategy.proto",
}

Strategy_ServiceDesc is the grpc.ServiceDesc for Strategy service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterStrategyHTTPServer

func RegisterStrategyHTTPServer(s *http.Server, srv StrategyHTTPServer)

func RegisterStrategyServer

func RegisterStrategyServer(s grpc.ServiceRegistrar, srv StrategyServer)

Types

type BatchDeleteStrategyReply

type BatchDeleteStrategyReply struct {

	// 策略ID列表, 成功后返回策略ID列表
	Ids []uint32 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

批量删除策略响应参数

func (*BatchDeleteStrategyReply) Descriptor deprecated

func (*BatchDeleteStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use BatchDeleteStrategyReply.ProtoReflect.Descriptor instead.

func (*BatchDeleteStrategyReply) GetIds

func (x *BatchDeleteStrategyReply) GetIds() []uint32

func (*BatchDeleteStrategyReply) ProtoMessage

func (*BatchDeleteStrategyReply) ProtoMessage()

func (*BatchDeleteStrategyReply) ProtoReflect

func (x *BatchDeleteStrategyReply) ProtoReflect() protoreflect.Message

func (*BatchDeleteStrategyReply) Reset

func (x *BatchDeleteStrategyReply) Reset()

func (*BatchDeleteStrategyReply) String

func (x *BatchDeleteStrategyReply) String() string

func (*BatchDeleteStrategyReply) Validate

func (m *BatchDeleteStrategyReply) Validate() error

Validate checks the field values on BatchDeleteStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BatchDeleteStrategyReply) ValidateAll

func (m *BatchDeleteStrategyReply) ValidateAll() error

ValidateAll checks the field values on BatchDeleteStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BatchDeleteStrategyReplyMultiError, or nil if none found.

type BatchDeleteStrategyReplyMultiError

type BatchDeleteStrategyReplyMultiError []error

BatchDeleteStrategyReplyMultiError is an error wrapping multiple validation errors returned by BatchDeleteStrategyReply.ValidateAll() if the designated constraints aren't met.

func (BatchDeleteStrategyReplyMultiError) AllErrors

func (m BatchDeleteStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (BatchDeleteStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BatchDeleteStrategyReplyValidationError

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

BatchDeleteStrategyReplyValidationError is the validation error returned by BatchDeleteStrategyReply.Validate if the designated constraints aren't met.

func (BatchDeleteStrategyReplyValidationError) Cause

Cause function returns cause value.

func (BatchDeleteStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (BatchDeleteStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (BatchDeleteStrategyReplyValidationError) Field

Field function returns field value.

func (BatchDeleteStrategyReplyValidationError) Key

Key function returns key value.

func (BatchDeleteStrategyReplyValidationError) Reason

Reason function returns reason value.

type BatchDeleteStrategyRequest

type BatchDeleteStrategyRequest struct {

	// 策略ID列表, 最少1个, 必须大于0, 唯一
	Ids []uint32 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

批量删除策略请求参数

func (*BatchDeleteStrategyRequest) Descriptor deprecated

func (*BatchDeleteStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use BatchDeleteStrategyRequest.ProtoReflect.Descriptor instead.

func (*BatchDeleteStrategyRequest) GetIds

func (x *BatchDeleteStrategyRequest) GetIds() []uint32

func (*BatchDeleteStrategyRequest) ProtoMessage

func (*BatchDeleteStrategyRequest) ProtoMessage()

func (*BatchDeleteStrategyRequest) ProtoReflect

func (*BatchDeleteStrategyRequest) Reset

func (x *BatchDeleteStrategyRequest) Reset()

func (*BatchDeleteStrategyRequest) String

func (x *BatchDeleteStrategyRequest) String() string

func (*BatchDeleteStrategyRequest) Validate

func (m *BatchDeleteStrategyRequest) Validate() error

Validate checks the field values on BatchDeleteStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BatchDeleteStrategyRequest) ValidateAll

func (m *BatchDeleteStrategyRequest) ValidateAll() error

ValidateAll checks the field values on BatchDeleteStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BatchDeleteStrategyRequestMultiError, or nil if none found.

type BatchDeleteStrategyRequestMultiError

type BatchDeleteStrategyRequestMultiError []error

BatchDeleteStrategyRequestMultiError is an error wrapping multiple validation errors returned by BatchDeleteStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (BatchDeleteStrategyRequestMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (BatchDeleteStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BatchDeleteStrategyRequestValidationError

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

BatchDeleteStrategyRequestValidationError is the validation error returned by BatchDeleteStrategyRequest.Validate if the designated constraints aren't met.

func (BatchDeleteStrategyRequestValidationError) Cause

Cause function returns cause value.

func (BatchDeleteStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (BatchDeleteStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (BatchDeleteStrategyRequestValidationError) Field

Field function returns field value.

func (BatchDeleteStrategyRequestValidationError) Key

Key function returns key value.

func (BatchDeleteStrategyRequestValidationError) Reason

Reason function returns reason value.

type BatchUpdateStrategyStatusReply

type BatchUpdateStrategyStatusReply struct {

	// 策略ID列表, 成功后返回策略ID列表
	Ids []uint32 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

批量更新策略状态响应参数

func (*BatchUpdateStrategyStatusReply) Descriptor deprecated

func (*BatchUpdateStrategyStatusReply) Descriptor() ([]byte, []int)

Deprecated: Use BatchUpdateStrategyStatusReply.ProtoReflect.Descriptor instead.

func (*BatchUpdateStrategyStatusReply) GetIds

func (x *BatchUpdateStrategyStatusReply) GetIds() []uint32

func (*BatchUpdateStrategyStatusReply) ProtoMessage

func (*BatchUpdateStrategyStatusReply) ProtoMessage()

func (*BatchUpdateStrategyStatusReply) ProtoReflect

func (*BatchUpdateStrategyStatusReply) Reset

func (x *BatchUpdateStrategyStatusReply) Reset()

func (*BatchUpdateStrategyStatusReply) String

func (*BatchUpdateStrategyStatusReply) Validate

func (m *BatchUpdateStrategyStatusReply) Validate() error

Validate checks the field values on BatchUpdateStrategyStatusReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BatchUpdateStrategyStatusReply) ValidateAll

func (m *BatchUpdateStrategyStatusReply) ValidateAll() error

ValidateAll checks the field values on BatchUpdateStrategyStatusReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BatchUpdateStrategyStatusReplyMultiError, or nil if none found.

type BatchUpdateStrategyStatusReplyMultiError

type BatchUpdateStrategyStatusReplyMultiError []error

BatchUpdateStrategyStatusReplyMultiError is an error wrapping multiple validation errors returned by BatchUpdateStrategyStatusReply.ValidateAll() if the designated constraints aren't met.

func (BatchUpdateStrategyStatusReplyMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (BatchUpdateStrategyStatusReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BatchUpdateStrategyStatusReplyValidationError

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

BatchUpdateStrategyStatusReplyValidationError is the validation error returned by BatchUpdateStrategyStatusReply.Validate if the designated constraints aren't met.

func (BatchUpdateStrategyStatusReplyValidationError) Cause

Cause function returns cause value.

func (BatchUpdateStrategyStatusReplyValidationError) Error

Error satisfies the builtin error interface

func (BatchUpdateStrategyStatusReplyValidationError) ErrorName

ErrorName returns error name.

func (BatchUpdateStrategyStatusReplyValidationError) Field

Field function returns field value.

func (BatchUpdateStrategyStatusReplyValidationError) Key

Key function returns key value.

func (BatchUpdateStrategyStatusReplyValidationError) Reason

Reason function returns reason value.

type BatchUpdateStrategyStatusRequest

type BatchUpdateStrategyStatusRequest struct {

	// 策略ID列表, 最少1个, 必须大于0, 唯一
	Ids []uint32 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// 策略状态, 不能为0
	Status api.Status `protobuf:"varint,2,opt,name=status,proto3,enum=api.Status" json:"status,omitempty"`
	// contains filtered or unexported fields
}

批量更新策略状态请求参数

func (*BatchUpdateStrategyStatusRequest) Descriptor deprecated

func (*BatchUpdateStrategyStatusRequest) Descriptor() ([]byte, []int)

Deprecated: Use BatchUpdateStrategyStatusRequest.ProtoReflect.Descriptor instead.

func (*BatchUpdateStrategyStatusRequest) GetIds

func (*BatchUpdateStrategyStatusRequest) GetStatus

func (*BatchUpdateStrategyStatusRequest) ProtoMessage

func (*BatchUpdateStrategyStatusRequest) ProtoMessage()

func (*BatchUpdateStrategyStatusRequest) ProtoReflect

func (*BatchUpdateStrategyStatusRequest) Reset

func (*BatchUpdateStrategyStatusRequest) String

func (*BatchUpdateStrategyStatusRequest) Validate

Validate checks the field values on BatchUpdateStrategyStatusRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BatchUpdateStrategyStatusRequest) ValidateAll

func (m *BatchUpdateStrategyStatusRequest) ValidateAll() error

ValidateAll checks the field values on BatchUpdateStrategyStatusRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BatchUpdateStrategyStatusRequestMultiError, or nil if none found.

type BatchUpdateStrategyStatusRequestMultiError

type BatchUpdateStrategyStatusRequestMultiError []error

BatchUpdateStrategyStatusRequestMultiError is an error wrapping multiple validation errors returned by BatchUpdateStrategyStatusRequest.ValidateAll() if the designated constraints aren't met.

func (BatchUpdateStrategyStatusRequestMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (BatchUpdateStrategyStatusRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BatchUpdateStrategyStatusRequestValidationError

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

BatchUpdateStrategyStatusRequestValidationError is the validation error returned by BatchUpdateStrategyStatusRequest.Validate if the designated constraints aren't met.

func (BatchUpdateStrategyStatusRequestValidationError) Cause

Cause function returns cause value.

func (BatchUpdateStrategyStatusRequestValidationError) Error

Error satisfies the builtin error interface

func (BatchUpdateStrategyStatusRequestValidationError) ErrorName

ErrorName returns error name.

func (BatchUpdateStrategyStatusRequestValidationError) Field

Field function returns field value.

func (BatchUpdateStrategyStatusRequestValidationError) Key

Key function returns key value.

func (BatchUpdateStrategyStatusRequestValidationError) Reason

Reason function returns reason value.

type BindStrategyNotifyObjectReply

type BindStrategyNotifyObjectReply struct {

	// 策略ID, 成功返回策略ID
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

绑定通知对象响应参数

func (*BindStrategyNotifyObjectReply) Descriptor deprecated

func (*BindStrategyNotifyObjectReply) Descriptor() ([]byte, []int)

Deprecated: Use BindStrategyNotifyObjectReply.ProtoReflect.Descriptor instead.

func (*BindStrategyNotifyObjectReply) GetId

func (*BindStrategyNotifyObjectReply) ProtoMessage

func (*BindStrategyNotifyObjectReply) ProtoMessage()

func (*BindStrategyNotifyObjectReply) ProtoReflect

func (*BindStrategyNotifyObjectReply) Reset

func (x *BindStrategyNotifyObjectReply) Reset()

func (*BindStrategyNotifyObjectReply) String

func (*BindStrategyNotifyObjectReply) Validate

func (m *BindStrategyNotifyObjectReply) Validate() error

Validate checks the field values on BindStrategyNotifyObjectReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BindStrategyNotifyObjectReply) ValidateAll

func (m *BindStrategyNotifyObjectReply) ValidateAll() error

ValidateAll checks the field values on BindStrategyNotifyObjectReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BindStrategyNotifyObjectReplyMultiError, or nil if none found.

type BindStrategyNotifyObjectReplyMultiError

type BindStrategyNotifyObjectReplyMultiError []error

BindStrategyNotifyObjectReplyMultiError is an error wrapping multiple validation errors returned by BindStrategyNotifyObjectReply.ValidateAll() if the designated constraints aren't met.

func (BindStrategyNotifyObjectReplyMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (BindStrategyNotifyObjectReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BindStrategyNotifyObjectReplyValidationError

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

BindStrategyNotifyObjectReplyValidationError is the validation error returned by BindStrategyNotifyObjectReply.Validate if the designated constraints aren't met.

func (BindStrategyNotifyObjectReplyValidationError) Cause

Cause function returns cause value.

func (BindStrategyNotifyObjectReplyValidationError) Error

Error satisfies the builtin error interface

func (BindStrategyNotifyObjectReplyValidationError) ErrorName

ErrorName returns error name.

func (BindStrategyNotifyObjectReplyValidationError) Field

Field function returns field value.

func (BindStrategyNotifyObjectReplyValidationError) Key

Key function returns key value.

func (BindStrategyNotifyObjectReplyValidationError) Reason

Reason function returns reason value.

type BindStrategyNotifyObjectRequest

type BindStrategyNotifyObjectRequest struct {

	// 策略ID, 路径参数, 必填, 大于0
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// 通知对象列表
	NotifyObjectIds []uint32 `protobuf:"varint,2,rep,packed,name=notifyObjectIds,proto3" json:"notifyObjectIds,omitempty"`
	// contains filtered or unexported fields
}

绑定通知对象请求参数

func (*BindStrategyNotifyObjectRequest) Descriptor deprecated

func (*BindStrategyNotifyObjectRequest) Descriptor() ([]byte, []int)

Deprecated: Use BindStrategyNotifyObjectRequest.ProtoReflect.Descriptor instead.

func (*BindStrategyNotifyObjectRequest) GetId

func (*BindStrategyNotifyObjectRequest) GetNotifyObjectIds

func (x *BindStrategyNotifyObjectRequest) GetNotifyObjectIds() []uint32

func (*BindStrategyNotifyObjectRequest) ProtoMessage

func (*BindStrategyNotifyObjectRequest) ProtoMessage()

func (*BindStrategyNotifyObjectRequest) ProtoReflect

func (*BindStrategyNotifyObjectRequest) Reset

func (*BindStrategyNotifyObjectRequest) String

func (*BindStrategyNotifyObjectRequest) Validate

func (m *BindStrategyNotifyObjectRequest) Validate() error

Validate checks the field values on BindStrategyNotifyObjectRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BindStrategyNotifyObjectRequest) ValidateAll

func (m *BindStrategyNotifyObjectRequest) ValidateAll() error

ValidateAll checks the field values on BindStrategyNotifyObjectRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BindStrategyNotifyObjectRequestMultiError, or nil if none found.

type BindStrategyNotifyObjectRequestMultiError

type BindStrategyNotifyObjectRequestMultiError []error

BindStrategyNotifyObjectRequestMultiError is an error wrapping multiple validation errors returned by BindStrategyNotifyObjectRequest.ValidateAll() if the designated constraints aren't met.

func (BindStrategyNotifyObjectRequestMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (BindStrategyNotifyObjectRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type BindStrategyNotifyObjectRequestValidationError

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

BindStrategyNotifyObjectRequestValidationError is the validation error returned by BindStrategyNotifyObjectRequest.Validate if the designated constraints aren't met.

func (BindStrategyNotifyObjectRequestValidationError) Cause

Cause function returns cause value.

func (BindStrategyNotifyObjectRequestValidationError) Error

Error satisfies the builtin error interface

func (BindStrategyNotifyObjectRequestValidationError) ErrorName

ErrorName returns error name.

func (BindStrategyNotifyObjectRequestValidationError) Field

Field function returns field value.

func (BindStrategyNotifyObjectRequestValidationError) Key

Key function returns key value.

func (BindStrategyNotifyObjectRequestValidationError) Reason

Reason function returns reason value.

type CreateStrategyReply

type CreateStrategyReply struct {

	// id 策略ID, 成功返回策略ID
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

创建策略响应参数

func (*CreateStrategyReply) Descriptor deprecated

func (*CreateStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use CreateStrategyReply.ProtoReflect.Descriptor instead.

func (*CreateStrategyReply) GetId

func (x *CreateStrategyReply) GetId() uint32

func (*CreateStrategyReply) ProtoMessage

func (*CreateStrategyReply) ProtoMessage()

func (*CreateStrategyReply) ProtoReflect

func (x *CreateStrategyReply) ProtoReflect() protoreflect.Message

func (*CreateStrategyReply) Reset

func (x *CreateStrategyReply) Reset()

func (*CreateStrategyReply) String

func (x *CreateStrategyReply) String() string

func (*CreateStrategyReply) Validate

func (m *CreateStrategyReply) Validate() error

Validate checks the field values on CreateStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CreateStrategyReply) ValidateAll

func (m *CreateStrategyReply) ValidateAll() error

ValidateAll checks the field values on CreateStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CreateStrategyReplyMultiError, or nil if none found.

type CreateStrategyReplyMultiError

type CreateStrategyReplyMultiError []error

CreateStrategyReplyMultiError is an error wrapping multiple validation errors returned by CreateStrategyReply.ValidateAll() if the designated constraints aren't met.

func (CreateStrategyReplyMultiError) AllErrors

func (m CreateStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CreateStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type CreateStrategyReplyValidationError

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

CreateStrategyReplyValidationError is the validation error returned by CreateStrategyReply.Validate if the designated constraints aren't met.

func (CreateStrategyReplyValidationError) Cause

Cause function returns cause value.

func (CreateStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (CreateStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (CreateStrategyReplyValidationError) Field

Field function returns field value.

func (CreateStrategyReplyValidationError) Key

Key function returns key value.

func (CreateStrategyReplyValidationError) Reason

Reason function returns reason value.

type CreateStrategyRequest

type CreateStrategyRequest struct {

	// 策略组ID, 必填, 所属的策略组ID信息
	GroupId uint32 `protobuf:"varint,1,opt,name=groupId,proto3" json:"groupId,omitempty"`
	// 告警名称, 必填, 字符串, 长度限制: 1-255, 正则表达式: ^[a-zA-Z0-9_]+$
	Alert string `protobuf:"bytes,2,opt,name=alert,proto3" json:"alert,omitempty"`
	// 表达式, 必填, promQL表达式
	Expr string `protobuf:"bytes,3,opt,name=expr,proto3" json:"expr,omitempty"`
	// 持续时间,(1s,1m,1h,1d), 对应prometheus的持续时间单位for
	Duration *api.Duration `protobuf:"bytes,4,opt,name=duration,proto3" json:"duration,omitempty"`
	// 标签, keys 长度限制: 1-32, 正则表达式: ^[a-zA-Z0-9_]+$
	Labels map[string]string `` /* 153-byte string literal not displayed */
	// 注解, keys 长度限制: 1-32, 正则表达式: ^[a-zA-Z0-9_]+$
	Annotations map[string]string `` /* 163-byte string literal not displayed */
	// 告警页面ID列表, 对应告警页面的ID
	AlarmPageIds []uint32 `protobuf:"varint,7,rep,packed,name=alarmPageIds,proto3" json:"alarmPageIds,omitempty"`
	// 分类ID列表, 对应字典表ID
	CategoryIds []uint32 `protobuf:"varint,8,rep,packed,name=categoryIds,proto3" json:"categoryIds,omitempty"`
	// 告警级别ID, 对应字典表ID(告警等级维护在字典表中)
	AlarmLevelId uint32 `protobuf:"varint,9,opt,name=alarmLevelId,proto3" json:"alarmLevelId,omitempty"`
	// 备注, 长度限制: 0-255
	Remark string `protobuf:"bytes,10,opt,name=remark,proto3" json:"remark,omitempty"`
	// 数据源
	DataSourceId uint32 `protobuf:"varint,11,opt,name=dataSourceId,proto3" json:"dataSourceId,omitempty"`
	// 最大抑制时常
	MaxSuppress *api.Duration `protobuf:"bytes,12,opt,name=maxSuppress,proto3" json:"maxSuppress,omitempty"`
	// 告警通知间隔
	SendInterval *api.Duration `protobuf:"bytes,13,opt,name=sendInterval,proto3" json:"sendInterval,omitempty"`
	// 是否发送告警通知
	SendRecover bool `protobuf:"varint,14,opt,name=sendRecover,proto3" json:"sendRecover,omitempty"`
	// contains filtered or unexported fields
}

创建策略请求参数

func (*CreateStrategyRequest) Descriptor deprecated

func (*CreateStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use CreateStrategyRequest.ProtoReflect.Descriptor instead.

func (*CreateStrategyRequest) GetAlarmLevelId

func (x *CreateStrategyRequest) GetAlarmLevelId() uint32

func (*CreateStrategyRequest) GetAlarmPageIds

func (x *CreateStrategyRequest) GetAlarmPageIds() []uint32

func (*CreateStrategyRequest) GetAlert

func (x *CreateStrategyRequest) GetAlert() string

func (*CreateStrategyRequest) GetAnnotations

func (x *CreateStrategyRequest) GetAnnotations() map[string]string

func (*CreateStrategyRequest) GetCategoryIds

func (x *CreateStrategyRequest) GetCategoryIds() []uint32

func (*CreateStrategyRequest) GetDataSourceId

func (x *CreateStrategyRequest) GetDataSourceId() uint32

func (*CreateStrategyRequest) GetDuration

func (x *CreateStrategyRequest) GetDuration() *api.Duration

func (*CreateStrategyRequest) GetExpr

func (x *CreateStrategyRequest) GetExpr() string

func (*CreateStrategyRequest) GetGroupId

func (x *CreateStrategyRequest) GetGroupId() uint32

func (*CreateStrategyRequest) GetLabels

func (x *CreateStrategyRequest) GetLabels() map[string]string

func (*CreateStrategyRequest) GetMaxSuppress

func (x *CreateStrategyRequest) GetMaxSuppress() *api.Duration

func (*CreateStrategyRequest) GetRemark

func (x *CreateStrategyRequest) GetRemark() string

func (*CreateStrategyRequest) GetSendInterval

func (x *CreateStrategyRequest) GetSendInterval() *api.Duration

func (*CreateStrategyRequest) GetSendRecover

func (x *CreateStrategyRequest) GetSendRecover() bool

func (*CreateStrategyRequest) ProtoMessage

func (*CreateStrategyRequest) ProtoMessage()

func (*CreateStrategyRequest) ProtoReflect

func (x *CreateStrategyRequest) ProtoReflect() protoreflect.Message

func (*CreateStrategyRequest) Reset

func (x *CreateStrategyRequest) Reset()

func (*CreateStrategyRequest) String

func (x *CreateStrategyRequest) String() string

func (*CreateStrategyRequest) Validate

func (m *CreateStrategyRequest) Validate() error

Validate checks the field values on CreateStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CreateStrategyRequest) ValidateAll

func (m *CreateStrategyRequest) ValidateAll() error

ValidateAll checks the field values on CreateStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CreateStrategyRequestMultiError, or nil if none found.

type CreateStrategyRequestMultiError

type CreateStrategyRequestMultiError []error

CreateStrategyRequestMultiError is an error wrapping multiple validation errors returned by CreateStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (CreateStrategyRequestMultiError) AllErrors

func (m CreateStrategyRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CreateStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type CreateStrategyRequestValidationError

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

CreateStrategyRequestValidationError is the validation error returned by CreateStrategyRequest.Validate if the designated constraints aren't met.

func (CreateStrategyRequestValidationError) Cause

Cause function returns cause value.

func (CreateStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (CreateStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (CreateStrategyRequestValidationError) Field

Field function returns field value.

func (CreateStrategyRequestValidationError) Key

Key function returns key value.

func (CreateStrategyRequestValidationError) Reason

Reason function returns reason value.

type DeleteStrategyReply

type DeleteStrategyReply struct {

	// 策略ID, 成功返回策略ID
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

删除策略响应参数

func (*DeleteStrategyReply) Descriptor deprecated

func (*DeleteStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use DeleteStrategyReply.ProtoReflect.Descriptor instead.

func (*DeleteStrategyReply) GetId

func (x *DeleteStrategyReply) GetId() uint32

func (*DeleteStrategyReply) ProtoMessage

func (*DeleteStrategyReply) ProtoMessage()

func (*DeleteStrategyReply) ProtoReflect

func (x *DeleteStrategyReply) ProtoReflect() protoreflect.Message

func (*DeleteStrategyReply) Reset

func (x *DeleteStrategyReply) Reset()

func (*DeleteStrategyReply) String

func (x *DeleteStrategyReply) String() string

func (*DeleteStrategyReply) Validate

func (m *DeleteStrategyReply) Validate() error

Validate checks the field values on DeleteStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*DeleteStrategyReply) ValidateAll

func (m *DeleteStrategyReply) ValidateAll() error

ValidateAll checks the field values on DeleteStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DeleteStrategyReplyMultiError, or nil if none found.

type DeleteStrategyReplyMultiError

type DeleteStrategyReplyMultiError []error

DeleteStrategyReplyMultiError is an error wrapping multiple validation errors returned by DeleteStrategyReply.ValidateAll() if the designated constraints aren't met.

func (DeleteStrategyReplyMultiError) AllErrors

func (m DeleteStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DeleteStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type DeleteStrategyReplyValidationError

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

DeleteStrategyReplyValidationError is the validation error returned by DeleteStrategyReply.Validate if the designated constraints aren't met.

func (DeleteStrategyReplyValidationError) Cause

Cause function returns cause value.

func (DeleteStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (DeleteStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (DeleteStrategyReplyValidationError) Field

Field function returns field value.

func (DeleteStrategyReplyValidationError) Key

Key function returns key value.

func (DeleteStrategyReplyValidationError) Reason

Reason function returns reason value.

type DeleteStrategyRequest

type DeleteStrategyRequest struct {

	// 策略ID, 路径参数, 必填, 大于0
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

删除策略请求参数

func (*DeleteStrategyRequest) Descriptor deprecated

func (*DeleteStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use DeleteStrategyRequest.ProtoReflect.Descriptor instead.

func (*DeleteStrategyRequest) GetId

func (x *DeleteStrategyRequest) GetId() uint32

func (*DeleteStrategyRequest) ProtoMessage

func (*DeleteStrategyRequest) ProtoMessage()

func (*DeleteStrategyRequest) ProtoReflect

func (x *DeleteStrategyRequest) ProtoReflect() protoreflect.Message

func (*DeleteStrategyRequest) Reset

func (x *DeleteStrategyRequest) Reset()

func (*DeleteStrategyRequest) String

func (x *DeleteStrategyRequest) String() string

func (*DeleteStrategyRequest) Validate

func (m *DeleteStrategyRequest) Validate() error

Validate checks the field values on DeleteStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*DeleteStrategyRequest) ValidateAll

func (m *DeleteStrategyRequest) ValidateAll() error

ValidateAll checks the field values on DeleteStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DeleteStrategyRequestMultiError, or nil if none found.

type DeleteStrategyRequestMultiError

type DeleteStrategyRequestMultiError []error

DeleteStrategyRequestMultiError is an error wrapping multiple validation errors returned by DeleteStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (DeleteStrategyRequestMultiError) AllErrors

func (m DeleteStrategyRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DeleteStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type DeleteStrategyRequestValidationError

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

DeleteStrategyRequestValidationError is the validation error returned by DeleteStrategyRequest.Validate if the designated constraints aren't met.

func (DeleteStrategyRequestValidationError) Cause

Cause function returns cause value.

func (DeleteStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (DeleteStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (DeleteStrategyRequestValidationError) Field

Field function returns field value.

func (DeleteStrategyRequestValidationError) Key

Key function returns key value.

func (DeleteStrategyRequestValidationError) Reason

Reason function returns reason value.

type ExportStrategyReply

type ExportStrategyReply struct {

	// 导出的策略文件bytes
	File []byte `protobuf:"bytes,1,opt,name=file,proto3" json:"file,omitempty"`
	// 导出的策略文件名
	FileName string `protobuf:"bytes,2,opt,name=fileName,proto3" json:"fileName,omitempty"`
	// contains filtered or unexported fields
}

导出策略响应

func (*ExportStrategyReply) Descriptor deprecated

func (*ExportStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use ExportStrategyReply.ProtoReflect.Descriptor instead.

func (*ExportStrategyReply) GetFile

func (x *ExportStrategyReply) GetFile() []byte

func (*ExportStrategyReply) GetFileName

func (x *ExportStrategyReply) GetFileName() string

func (*ExportStrategyReply) ProtoMessage

func (*ExportStrategyReply) ProtoMessage()

func (*ExportStrategyReply) ProtoReflect

func (x *ExportStrategyReply) ProtoReflect() protoreflect.Message

func (*ExportStrategyReply) Reset

func (x *ExportStrategyReply) Reset()

func (*ExportStrategyReply) String

func (x *ExportStrategyReply) String() string

func (*ExportStrategyReply) Validate

func (m *ExportStrategyReply) Validate() error

Validate checks the field values on ExportStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*ExportStrategyReply) ValidateAll

func (m *ExportStrategyReply) ValidateAll() error

ValidateAll checks the field values on ExportStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in ExportStrategyReplyMultiError, or nil if none found.

type ExportStrategyReplyMultiError

type ExportStrategyReplyMultiError []error

ExportStrategyReplyMultiError is an error wrapping multiple validation errors returned by ExportStrategyReply.ValidateAll() if the designated constraints aren't met.

func (ExportStrategyReplyMultiError) AllErrors

func (m ExportStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ExportStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type ExportStrategyReplyValidationError

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

ExportStrategyReplyValidationError is the validation error returned by ExportStrategyReply.Validate if the designated constraints aren't met.

func (ExportStrategyReplyValidationError) Cause

Cause function returns cause value.

func (ExportStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (ExportStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (ExportStrategyReplyValidationError) Field

Field function returns field value.

func (ExportStrategyReplyValidationError) Key

Key function returns key value.

func (ExportStrategyReplyValidationError) Reason

Reason function returns reason value.

type ExportStrategyRequest

type ExportStrategyRequest struct {

	// 需要导出的策略ID列表, 最少1个, 必须大于0, 唯一
	Ids []uint32 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

导出策略请求参数

func (*ExportStrategyRequest) Descriptor deprecated

func (*ExportStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use ExportStrategyRequest.ProtoReflect.Descriptor instead.

func (*ExportStrategyRequest) GetIds

func (x *ExportStrategyRequest) GetIds() []uint32

func (*ExportStrategyRequest) ProtoMessage

func (*ExportStrategyRequest) ProtoMessage()

func (*ExportStrategyRequest) ProtoReflect

func (x *ExportStrategyRequest) ProtoReflect() protoreflect.Message

func (*ExportStrategyRequest) Reset

func (x *ExportStrategyRequest) Reset()

func (*ExportStrategyRequest) String

func (x *ExportStrategyRequest) String() string

func (*ExportStrategyRequest) Validate

func (m *ExportStrategyRequest) Validate() error

Validate checks the field values on ExportStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*ExportStrategyRequest) ValidateAll

func (m *ExportStrategyRequest) ValidateAll() error

ValidateAll checks the field values on ExportStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in ExportStrategyRequestMultiError, or nil if none found.

type ExportStrategyRequestMultiError

type ExportStrategyRequestMultiError []error

ExportStrategyRequestMultiError is an error wrapping multiple validation errors returned by ExportStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (ExportStrategyRequestMultiError) AllErrors

func (m ExportStrategyRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ExportStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type ExportStrategyRequestValidationError

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

ExportStrategyRequestValidationError is the validation error returned by ExportStrategyRequest.Validate if the designated constraints aren't met.

func (ExportStrategyRequestValidationError) Cause

Cause function returns cause value.

func (ExportStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (ExportStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (ExportStrategyRequestValidationError) Field

Field function returns field value.

func (ExportStrategyRequestValidationError) Key

Key function returns key value.

func (ExportStrategyRequestValidationError) Reason

Reason function returns reason value.

type GetStrategyNotifyObjectReply

type GetStrategyNotifyObjectReply struct {

	// 策略通知对象列表
	Detail           *api.PromStrategyV1 `protobuf:"bytes,1,opt,name=detail,proto3" json:"detail,omitempty"`
	NotifyObjectList []*api.NotifyV1     `protobuf:"bytes,2,rep,name=notifyObjectList,proto3" json:"notifyObjectList,omitempty"`
	// contains filtered or unexported fields
}

获取策略通知对象响应参数

func (*GetStrategyNotifyObjectReply) Descriptor deprecated

func (*GetStrategyNotifyObjectReply) Descriptor() ([]byte, []int)

Deprecated: Use GetStrategyNotifyObjectReply.ProtoReflect.Descriptor instead.

func (*GetStrategyNotifyObjectReply) GetDetail

func (*GetStrategyNotifyObjectReply) GetNotifyObjectList

func (x *GetStrategyNotifyObjectReply) GetNotifyObjectList() []*api.NotifyV1

func (*GetStrategyNotifyObjectReply) ProtoMessage

func (*GetStrategyNotifyObjectReply) ProtoMessage()

func (*GetStrategyNotifyObjectReply) ProtoReflect

func (*GetStrategyNotifyObjectReply) Reset

func (x *GetStrategyNotifyObjectReply) Reset()

func (*GetStrategyNotifyObjectReply) String

func (*GetStrategyNotifyObjectReply) Validate

func (m *GetStrategyNotifyObjectReply) Validate() error

Validate checks the field values on GetStrategyNotifyObjectReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*GetStrategyNotifyObjectReply) ValidateAll

func (m *GetStrategyNotifyObjectReply) ValidateAll() error

ValidateAll checks the field values on GetStrategyNotifyObjectReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in GetStrategyNotifyObjectReplyMultiError, or nil if none found.

type GetStrategyNotifyObjectReplyMultiError

type GetStrategyNotifyObjectReplyMultiError []error

GetStrategyNotifyObjectReplyMultiError is an error wrapping multiple validation errors returned by GetStrategyNotifyObjectReply.ValidateAll() if the designated constraints aren't met.

func (GetStrategyNotifyObjectReplyMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (GetStrategyNotifyObjectReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type GetStrategyNotifyObjectReplyValidationError

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

GetStrategyNotifyObjectReplyValidationError is the validation error returned by GetStrategyNotifyObjectReply.Validate if the designated constraints aren't met.

func (GetStrategyNotifyObjectReplyValidationError) Cause

Cause function returns cause value.

func (GetStrategyNotifyObjectReplyValidationError) Error

Error satisfies the builtin error interface

func (GetStrategyNotifyObjectReplyValidationError) ErrorName

ErrorName returns error name.

func (GetStrategyNotifyObjectReplyValidationError) Field

Field function returns field value.

func (GetStrategyNotifyObjectReplyValidationError) Key

Key function returns key value.

func (GetStrategyNotifyObjectReplyValidationError) Reason

Reason function returns reason value.

type GetStrategyNotifyObjectRequest

type GetStrategyNotifyObjectRequest struct {

	// 策略ID, 路径参数, 必填, 大于0
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

获取策略通知对象请求参数

func (*GetStrategyNotifyObjectRequest) Descriptor deprecated

func (*GetStrategyNotifyObjectRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetStrategyNotifyObjectRequest.ProtoReflect.Descriptor instead.

func (*GetStrategyNotifyObjectRequest) GetId

func (*GetStrategyNotifyObjectRequest) ProtoMessage

func (*GetStrategyNotifyObjectRequest) ProtoMessage()

func (*GetStrategyNotifyObjectRequest) ProtoReflect

func (*GetStrategyNotifyObjectRequest) Reset

func (x *GetStrategyNotifyObjectRequest) Reset()

func (*GetStrategyNotifyObjectRequest) String

func (*GetStrategyNotifyObjectRequest) Validate

func (m *GetStrategyNotifyObjectRequest) Validate() error

Validate checks the field values on GetStrategyNotifyObjectRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*GetStrategyNotifyObjectRequest) ValidateAll

func (m *GetStrategyNotifyObjectRequest) ValidateAll() error

ValidateAll checks the field values on GetStrategyNotifyObjectRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in GetStrategyNotifyObjectRequestMultiError, or nil if none found.

type GetStrategyNotifyObjectRequestMultiError

type GetStrategyNotifyObjectRequestMultiError []error

GetStrategyNotifyObjectRequestMultiError is an error wrapping multiple validation errors returned by GetStrategyNotifyObjectRequest.ValidateAll() if the designated constraints aren't met.

func (GetStrategyNotifyObjectRequestMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (GetStrategyNotifyObjectRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type GetStrategyNotifyObjectRequestValidationError

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

GetStrategyNotifyObjectRequestValidationError is the validation error returned by GetStrategyNotifyObjectRequest.Validate if the designated constraints aren't met.

func (GetStrategyNotifyObjectRequestValidationError) Cause

Cause function returns cause value.

func (GetStrategyNotifyObjectRequestValidationError) Error

Error satisfies the builtin error interface

func (GetStrategyNotifyObjectRequestValidationError) ErrorName

ErrorName returns error name.

func (GetStrategyNotifyObjectRequestValidationError) Field

Field function returns field value.

func (GetStrategyNotifyObjectRequestValidationError) Key

Key function returns key value.

func (GetStrategyNotifyObjectRequestValidationError) Reason

Reason function returns reason value.

type GetStrategyReply

type GetStrategyReply struct {

	// 策略信息
	Detail *api.PromStrategyV1 `protobuf:"bytes,1,opt,name=detail,proto3" json:"detail,omitempty"`
	// contains filtered or unexported fields
}

获取策略响应参数

func (*GetStrategyReply) Descriptor deprecated

func (*GetStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use GetStrategyReply.ProtoReflect.Descriptor instead.

func (*GetStrategyReply) GetDetail

func (x *GetStrategyReply) GetDetail() *api.PromStrategyV1

func (*GetStrategyReply) ProtoMessage

func (*GetStrategyReply) ProtoMessage()

func (*GetStrategyReply) ProtoReflect

func (x *GetStrategyReply) ProtoReflect() protoreflect.Message

func (*GetStrategyReply) Reset

func (x *GetStrategyReply) Reset()

func (*GetStrategyReply) String

func (x *GetStrategyReply) String() string

func (*GetStrategyReply) Validate

func (m *GetStrategyReply) Validate() error

Validate checks the field values on GetStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*GetStrategyReply) ValidateAll

func (m *GetStrategyReply) ValidateAll() error

ValidateAll checks the field values on GetStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in GetStrategyReplyMultiError, or nil if none found.

type GetStrategyReplyMultiError

type GetStrategyReplyMultiError []error

GetStrategyReplyMultiError is an error wrapping multiple validation errors returned by GetStrategyReply.ValidateAll() if the designated constraints aren't met.

func (GetStrategyReplyMultiError) AllErrors

func (m GetStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (GetStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type GetStrategyReplyValidationError

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

GetStrategyReplyValidationError is the validation error returned by GetStrategyReply.Validate if the designated constraints aren't met.

func (GetStrategyReplyValidationError) Cause

Cause function returns cause value.

func (GetStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (GetStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (GetStrategyReplyValidationError) Field

Field function returns field value.

func (GetStrategyReplyValidationError) Key

Key function returns key value.

func (GetStrategyReplyValidationError) Reason

Reason function returns reason value.

type GetStrategyRequest

type GetStrategyRequest struct {

	// 策略ID, 路径参数, 必填, 大于0
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

获取策略请求参数

func (*GetStrategyRequest) Descriptor deprecated

func (*GetStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetStrategyRequest.ProtoReflect.Descriptor instead.

func (*GetStrategyRequest) GetId

func (x *GetStrategyRequest) GetId() uint32

func (*GetStrategyRequest) ProtoMessage

func (*GetStrategyRequest) ProtoMessage()

func (*GetStrategyRequest) ProtoReflect

func (x *GetStrategyRequest) ProtoReflect() protoreflect.Message

func (*GetStrategyRequest) Reset

func (x *GetStrategyRequest) Reset()

func (*GetStrategyRequest) String

func (x *GetStrategyRequest) String() string

func (*GetStrategyRequest) Validate

func (m *GetStrategyRequest) Validate() error

Validate checks the field values on GetStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*GetStrategyRequest) ValidateAll

func (m *GetStrategyRequest) ValidateAll() error

ValidateAll checks the field values on GetStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in GetStrategyRequestMultiError, or nil if none found.

type GetStrategyRequestMultiError

type GetStrategyRequestMultiError []error

GetStrategyRequestMultiError is an error wrapping multiple validation errors returned by GetStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (GetStrategyRequestMultiError) AllErrors

func (m GetStrategyRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (GetStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type GetStrategyRequestValidationError

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

GetStrategyRequestValidationError is the validation error returned by GetStrategyRequest.Validate if the designated constraints aren't met.

func (GetStrategyRequestValidationError) Cause

Cause function returns cause value.

func (GetStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (GetStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (GetStrategyRequestValidationError) Field

Field function returns field value.

func (GetStrategyRequestValidationError) Key

Key function returns key value.

func (GetStrategyRequestValidationError) Reason

Reason function returns reason value.

type ListStrategyReply

type ListStrategyReply struct {

	// 分页参数
	Page *api.PageReply `protobuf:"bytes,1,opt,name=page,proto3" json:"page,omitempty"`
	// 策略列表
	List []*api.PromStrategyV1 `protobuf:"bytes,2,rep,name=list,proto3" json:"list,omitempty"`
	// contains filtered or unexported fields
}

获取策略列表响应参数

func (*ListStrategyReply) Descriptor deprecated

func (*ListStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use ListStrategyReply.ProtoReflect.Descriptor instead.

func (*ListStrategyReply) GetList

func (x *ListStrategyReply) GetList() []*api.PromStrategyV1

func (*ListStrategyReply) GetPage

func (x *ListStrategyReply) GetPage() *api.PageReply

func (*ListStrategyReply) ProtoMessage

func (*ListStrategyReply) ProtoMessage()

func (*ListStrategyReply) ProtoReflect

func (x *ListStrategyReply) ProtoReflect() protoreflect.Message

func (*ListStrategyReply) Reset

func (x *ListStrategyReply) Reset()

func (*ListStrategyReply) String

func (x *ListStrategyReply) String() string

func (*ListStrategyReply) Validate

func (m *ListStrategyReply) Validate() error

Validate checks the field values on ListStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*ListStrategyReply) ValidateAll

func (m *ListStrategyReply) ValidateAll() error

ValidateAll checks the field values on ListStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in ListStrategyReplyMultiError, or nil if none found.

type ListStrategyReplyMultiError

type ListStrategyReplyMultiError []error

ListStrategyReplyMultiError is an error wrapping multiple validation errors returned by ListStrategyReply.ValidateAll() if the designated constraints aren't met.

func (ListStrategyReplyMultiError) AllErrors

func (m ListStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ListStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type ListStrategyReplyValidationError

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

ListStrategyReplyValidationError is the validation error returned by ListStrategyReply.Validate if the designated constraints aren't met.

func (ListStrategyReplyValidationError) Cause

Cause function returns cause value.

func (ListStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (ListStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (ListStrategyReplyValidationError) Field

Field function returns field value.

func (ListStrategyReplyValidationError) Key

Key function returns key value.

func (ListStrategyReplyValidationError) Reason

Reason function returns reason value.

type ListStrategyRequest

type ListStrategyRequest struct {

	// 分页参数, 必填
	Page *api.PageRequest `protobuf:"bytes,1,opt,name=page,proto3" json:"page,omitempty"`
	// 关键字, 可选, 长度限制: 0-255, 用于模糊查询
	Keyword string `protobuf:"bytes,2,opt,name=keyword,proto3" json:"keyword,omitempty"`
	// 策略组ID, 可选, 用于查询指定策略组下的策略
	GroupId uint32 `protobuf:"varint,3,opt,name=groupId,proto3" json:"groupId,omitempty"`
	// 分类ID列表, 可选, 用于查询指定分类下的策略
	CategoryIds []uint32 `protobuf:"varint,4,rep,packed,name=categoryIds,proto3" json:"categoryIds,omitempty"`
	// 告警级别ID, 可选, 用于查询指定告警级别下的策略
	AlarmLevelId uint32 `protobuf:"varint,5,opt,name=alarmLevelId,proto3" json:"alarmLevelId,omitempty"`
	// 策略状态, 可选, 用于查询指定状态下的策略
	Status api.Status `protobuf:"varint,6,opt,name=status,proto3,enum=api.Status" json:"status,omitempty"`
	// 是否获取已删除的策略
	IsDeleted bool `protobuf:"varint,7,opt,name=isDeleted,proto3" json:"isDeleted,omitempty"`
	// 策略ID
	StrategyId uint32 `protobuf:"varint,8,opt,name=strategyId,proto3" json:"strategyId,omitempty"`
	// contains filtered or unexported fields
}

获取策略列表请求参数

func (*ListStrategyRequest) Descriptor deprecated

func (*ListStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListStrategyRequest.ProtoReflect.Descriptor instead.

func (*ListStrategyRequest) GetAlarmLevelId

func (x *ListStrategyRequest) GetAlarmLevelId() uint32

func (*ListStrategyRequest) GetCategoryIds

func (x *ListStrategyRequest) GetCategoryIds() []uint32

func (*ListStrategyRequest) GetGroupId

func (x *ListStrategyRequest) GetGroupId() uint32

func (*ListStrategyRequest) GetIsDeleted

func (x *ListStrategyRequest) GetIsDeleted() bool

func (*ListStrategyRequest) GetKeyword

func (x *ListStrategyRequest) GetKeyword() string

func (*ListStrategyRequest) GetPage

func (x *ListStrategyRequest) GetPage() *api.PageRequest

func (*ListStrategyRequest) GetStatus

func (x *ListStrategyRequest) GetStatus() api.Status

func (*ListStrategyRequest) GetStrategyId

func (x *ListStrategyRequest) GetStrategyId() uint32

func (*ListStrategyRequest) ProtoMessage

func (*ListStrategyRequest) ProtoMessage()

func (*ListStrategyRequest) ProtoReflect

func (x *ListStrategyRequest) ProtoReflect() protoreflect.Message

func (*ListStrategyRequest) Reset

func (x *ListStrategyRequest) Reset()

func (*ListStrategyRequest) String

func (x *ListStrategyRequest) String() string

func (*ListStrategyRequest) Validate

func (m *ListStrategyRequest) Validate() error

Validate checks the field values on ListStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*ListStrategyRequest) ValidateAll

func (m *ListStrategyRequest) ValidateAll() error

ValidateAll checks the field values on ListStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in ListStrategyRequestMultiError, or nil if none found.

type ListStrategyRequestMultiError

type ListStrategyRequestMultiError []error

ListStrategyRequestMultiError is an error wrapping multiple validation errors returned by ListStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (ListStrategyRequestMultiError) AllErrors

func (m ListStrategyRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ListStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type ListStrategyRequestValidationError

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

ListStrategyRequestValidationError is the validation error returned by ListStrategyRequest.Validate if the designated constraints aren't met.

func (ListStrategyRequestValidationError) Cause

Cause function returns cause value.

func (ListStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (ListStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (ListStrategyRequestValidationError) Field

Field function returns field value.

func (ListStrategyRequestValidationError) Key

Key function returns key value.

func (ListStrategyRequestValidationError) Reason

Reason function returns reason value.

type SelectStrategyReply

type SelectStrategyReply struct {

	// 分页参数
	Page *api.PageReply `protobuf:"bytes,1,opt,name=page,proto3" json:"page,omitempty"`
	// 策略下拉列表
	List []*api.PromStrategySelectV1 `protobuf:"bytes,2,rep,name=list,proto3" json:"list,omitempty"`
	// contains filtered or unexported fields
}

获取策略列表响应参数

func (*SelectStrategyReply) Descriptor deprecated

func (*SelectStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use SelectStrategyReply.ProtoReflect.Descriptor instead.

func (*SelectStrategyReply) GetList

func (*SelectStrategyReply) GetPage

func (x *SelectStrategyReply) GetPage() *api.PageReply

func (*SelectStrategyReply) ProtoMessage

func (*SelectStrategyReply) ProtoMessage()

func (*SelectStrategyReply) ProtoReflect

func (x *SelectStrategyReply) ProtoReflect() protoreflect.Message

func (*SelectStrategyReply) Reset

func (x *SelectStrategyReply) Reset()

func (*SelectStrategyReply) String

func (x *SelectStrategyReply) String() string

func (*SelectStrategyReply) Validate

func (m *SelectStrategyReply) Validate() error

Validate checks the field values on SelectStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*SelectStrategyReply) ValidateAll

func (m *SelectStrategyReply) ValidateAll() error

ValidateAll checks the field values on SelectStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in SelectStrategyReplyMultiError, or nil if none found.

type SelectStrategyReplyMultiError

type SelectStrategyReplyMultiError []error

SelectStrategyReplyMultiError is an error wrapping multiple validation errors returned by SelectStrategyReply.ValidateAll() if the designated constraints aren't met.

func (SelectStrategyReplyMultiError) AllErrors

func (m SelectStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SelectStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type SelectStrategyReplyValidationError

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

SelectStrategyReplyValidationError is the validation error returned by SelectStrategyReply.Validate if the designated constraints aren't met.

func (SelectStrategyReplyValidationError) Cause

Cause function returns cause value.

func (SelectStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (SelectStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (SelectStrategyReplyValidationError) Field

Field function returns field value.

func (SelectStrategyReplyValidationError) Key

Key function returns key value.

func (SelectStrategyReplyValidationError) Reason

Reason function returns reason value.

type SelectStrategyRequest

type SelectStrategyRequest struct {

	// 分页参数
	Page *api.PageRequest `protobuf:"bytes,1,opt,name=page,proto3" json:"page,omitempty"`
	// 关键字, 可选, 长度限制: 0-255, 用于模糊查询
	Keyword string `protobuf:"bytes,2,opt,name=keyword,proto3" json:"keyword,omitempty"`
	// 状态
	Status api.Status `protobuf:"varint,3,opt,name=status,proto3,enum=api.Status" json:"status,omitempty"`
	// contains filtered or unexported fields
}

获取策略下拉列表请求参数

func (*SelectStrategyRequest) Descriptor deprecated

func (*SelectStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use SelectStrategyRequest.ProtoReflect.Descriptor instead.

func (*SelectStrategyRequest) GetKeyword

func (x *SelectStrategyRequest) GetKeyword() string

func (*SelectStrategyRequest) GetPage

func (x *SelectStrategyRequest) GetPage() *api.PageRequest

func (*SelectStrategyRequest) GetStatus

func (x *SelectStrategyRequest) GetStatus() api.Status

func (*SelectStrategyRequest) ProtoMessage

func (*SelectStrategyRequest) ProtoMessage()

func (*SelectStrategyRequest) ProtoReflect

func (x *SelectStrategyRequest) ProtoReflect() protoreflect.Message

func (*SelectStrategyRequest) Reset

func (x *SelectStrategyRequest) Reset()

func (*SelectStrategyRequest) String

func (x *SelectStrategyRequest) String() string

func (*SelectStrategyRequest) Validate

func (m *SelectStrategyRequest) Validate() error

Validate checks the field values on SelectStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*SelectStrategyRequest) ValidateAll

func (m *SelectStrategyRequest) ValidateAll() error

ValidateAll checks the field values on SelectStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in SelectStrategyRequestMultiError, or nil if none found.

type SelectStrategyRequestMultiError

type SelectStrategyRequestMultiError []error

SelectStrategyRequestMultiError is an error wrapping multiple validation errors returned by SelectStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (SelectStrategyRequestMultiError) AllErrors

func (m SelectStrategyRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SelectStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type SelectStrategyRequestValidationError

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

SelectStrategyRequestValidationError is the validation error returned by SelectStrategyRequest.Validate if the designated constraints aren't met.

func (SelectStrategyRequestValidationError) Cause

Cause function returns cause value.

func (SelectStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (SelectStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (SelectStrategyRequestValidationError) Field

Field function returns field value.

func (SelectStrategyRequestValidationError) Key

Key function returns key value.

func (SelectStrategyRequestValidationError) Reason

Reason function returns reason value.

type StrategyClient

type StrategyClient interface {
	// 创建策略
	CreateStrategy(ctx context.Context, in *CreateStrategyRequest, opts ...grpc.CallOption) (*CreateStrategyReply, error)
	// 更新策略
	UpdateStrategy(ctx context.Context, in *UpdateStrategyRequest, opts ...grpc.CallOption) (*UpdateStrategyReply, error)
	// 批量更新策略状态
	BatchUpdateStrategyStatus(ctx context.Context, in *BatchUpdateStrategyStatusRequest, opts ...grpc.CallOption) (*BatchUpdateStrategyStatusReply, error)
	// 删除策略
	DeleteStrategy(ctx context.Context, in *DeleteStrategyRequest, opts ...grpc.CallOption) (*DeleteStrategyReply, error)
	// 批量删除策略
	BatchDeleteStrategy(ctx context.Context, in *BatchDeleteStrategyRequest, opts ...grpc.CallOption) (*BatchDeleteStrategyReply, error)
	// 获取策略
	GetStrategy(ctx context.Context, in *GetStrategyRequest, opts ...grpc.CallOption) (*GetStrategyReply, error)
	// 获取策略列表
	ListStrategy(ctx context.Context, in *ListStrategyRequest, opts ...grpc.CallOption) (*ListStrategyReply, error)
	// 获取策略下拉列表
	SelectStrategy(ctx context.Context, in *SelectStrategyRequest, opts ...grpc.CallOption) (*SelectStrategyReply, error)
	// ExportStrategy 导出策略
	ExportStrategy(ctx context.Context, in *ExportStrategyRequest, opts ...grpc.CallOption) (*ExportStrategyReply, error)
	// 获取策略通知对象明细
	GetStrategyNotifyObject(ctx context.Context, in *GetStrategyNotifyObjectRequest, opts ...grpc.CallOption) (*GetStrategyNotifyObjectReply, error)
	// 绑定通知对象
	BindStrategyNotifyObject(ctx context.Context, in *BindStrategyNotifyObjectRequest, opts ...grpc.CallOption) (*BindStrategyNotifyObjectReply, error)
	// 测试hook模板
	TestNotifyTemplate(ctx context.Context, in *TestTemplateRequest, opts ...grpc.CallOption) (*TestTemplateReply, error)
}

StrategyClient is the client API for Strategy service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewStrategyClient

func NewStrategyClient(cc grpc.ClientConnInterface) StrategyClient

type StrategyHTTPClient

type StrategyHTTPClient interface {
	BatchDeleteStrategy(ctx context.Context, req *BatchDeleteStrategyRequest, opts ...http.CallOption) (rsp *BatchDeleteStrategyReply, err error)
	BatchUpdateStrategyStatus(ctx context.Context, req *BatchUpdateStrategyStatusRequest, opts ...http.CallOption) (rsp *BatchUpdateStrategyStatusReply, err error)
	BindStrategyNotifyObject(ctx context.Context, req *BindStrategyNotifyObjectRequest, opts ...http.CallOption) (rsp *BindStrategyNotifyObjectReply, err error)
	CreateStrategy(ctx context.Context, req *CreateStrategyRequest, opts ...http.CallOption) (rsp *CreateStrategyReply, err error)
	DeleteStrategy(ctx context.Context, req *DeleteStrategyRequest, opts ...http.CallOption) (rsp *DeleteStrategyReply, err error)
	ExportStrategy(ctx context.Context, req *ExportStrategyRequest, opts ...http.CallOption) (rsp *ExportStrategyReply, err error)
	GetStrategy(ctx context.Context, req *GetStrategyRequest, opts ...http.CallOption) (rsp *GetStrategyReply, err error)
	GetStrategyNotifyObject(ctx context.Context, req *GetStrategyNotifyObjectRequest, opts ...http.CallOption) (rsp *GetStrategyNotifyObjectReply, err error)
	ListStrategy(ctx context.Context, req *ListStrategyRequest, opts ...http.CallOption) (rsp *ListStrategyReply, err error)
	SelectStrategy(ctx context.Context, req *SelectStrategyRequest, opts ...http.CallOption) (rsp *SelectStrategyReply, err error)
	TestNotifyTemplate(ctx context.Context, req *TestTemplateRequest, opts ...http.CallOption) (rsp *TestTemplateReply, err error)
	UpdateStrategy(ctx context.Context, req *UpdateStrategyRequest, opts ...http.CallOption) (rsp *UpdateStrategyReply, err error)
}

func NewStrategyHTTPClient

func NewStrategyHTTPClient(client *http.Client) StrategyHTTPClient

type StrategyHTTPClientImpl

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

func (*StrategyHTTPClientImpl) BatchDeleteStrategy

func (*StrategyHTTPClientImpl) BatchUpdateStrategyStatus

func (*StrategyHTTPClientImpl) BindStrategyNotifyObject

func (*StrategyHTTPClientImpl) CreateStrategy

func (*StrategyHTTPClientImpl) DeleteStrategy

func (*StrategyHTTPClientImpl) ExportStrategy

func (*StrategyHTTPClientImpl) GetStrategy

func (*StrategyHTTPClientImpl) GetStrategyNotifyObject

func (*StrategyHTTPClientImpl) ListStrategy

func (*StrategyHTTPClientImpl) SelectStrategy

func (*StrategyHTTPClientImpl) TestNotifyTemplate

func (c *StrategyHTTPClientImpl) TestNotifyTemplate(ctx context.Context, in *TestTemplateRequest, opts ...http.CallOption) (*TestTemplateReply, error)

func (*StrategyHTTPClientImpl) UpdateStrategy

type StrategyHTTPServer

type StrategyHTTPServer interface {
	// BatchDeleteStrategy 批量删除策略
	BatchDeleteStrategy(context.Context, *BatchDeleteStrategyRequest) (*BatchDeleteStrategyReply, error)
	// BatchUpdateStrategyStatus 批量更新策略状态
	BatchUpdateStrategyStatus(context.Context, *BatchUpdateStrategyStatusRequest) (*BatchUpdateStrategyStatusReply, error)
	// BindStrategyNotifyObject 绑定通知对象
	BindStrategyNotifyObject(context.Context, *BindStrategyNotifyObjectRequest) (*BindStrategyNotifyObjectReply, error)
	// CreateStrategy 创建策略
	CreateStrategy(context.Context, *CreateStrategyRequest) (*CreateStrategyReply, error)
	// DeleteStrategy 删除策略
	DeleteStrategy(context.Context, *DeleteStrategyRequest) (*DeleteStrategyReply, error)
	// ExportStrategy ExportStrategy 导出策略
	ExportStrategy(context.Context, *ExportStrategyRequest) (*ExportStrategyReply, error)
	// GetStrategy 获取策略
	GetStrategy(context.Context, *GetStrategyRequest) (*GetStrategyReply, error)
	// GetStrategyNotifyObject 获取策略通知对象明细
	GetStrategyNotifyObject(context.Context, *GetStrategyNotifyObjectRequest) (*GetStrategyNotifyObjectReply, error)
	// ListStrategy 获取策略列表
	ListStrategy(context.Context, *ListStrategyRequest) (*ListStrategyReply, error)
	// SelectStrategy 获取策略下拉列表
	SelectStrategy(context.Context, *SelectStrategyRequest) (*SelectStrategyReply, error)
	// TestNotifyTemplate 测试hook模板
	TestNotifyTemplate(context.Context, *TestTemplateRequest) (*TestTemplateReply, error)
	// UpdateStrategy 更新策略
	UpdateStrategy(context.Context, *UpdateStrategyRequest) (*UpdateStrategyReply, error)
}

type StrategyServer

type StrategyServer interface {
	// 创建策略
	CreateStrategy(context.Context, *CreateStrategyRequest) (*CreateStrategyReply, error)
	// 更新策略
	UpdateStrategy(context.Context, *UpdateStrategyRequest) (*UpdateStrategyReply, error)
	// 批量更新策略状态
	BatchUpdateStrategyStatus(context.Context, *BatchUpdateStrategyStatusRequest) (*BatchUpdateStrategyStatusReply, error)
	// 删除策略
	DeleteStrategy(context.Context, *DeleteStrategyRequest) (*DeleteStrategyReply, error)
	// 批量删除策略
	BatchDeleteStrategy(context.Context, *BatchDeleteStrategyRequest) (*BatchDeleteStrategyReply, error)
	// 获取策略
	GetStrategy(context.Context, *GetStrategyRequest) (*GetStrategyReply, error)
	// 获取策略列表
	ListStrategy(context.Context, *ListStrategyRequest) (*ListStrategyReply, error)
	// 获取策略下拉列表
	SelectStrategy(context.Context, *SelectStrategyRequest) (*SelectStrategyReply, error)
	// ExportStrategy 导出策略
	ExportStrategy(context.Context, *ExportStrategyRequest) (*ExportStrategyReply, error)
	// 获取策略通知对象明细
	GetStrategyNotifyObject(context.Context, *GetStrategyNotifyObjectRequest) (*GetStrategyNotifyObjectReply, error)
	// 绑定通知对象
	BindStrategyNotifyObject(context.Context, *BindStrategyNotifyObjectRequest) (*BindStrategyNotifyObjectReply, error)
	// 测试hook模板
	TestNotifyTemplate(context.Context, *TestTemplateRequest) (*TestTemplateReply, error)
	// contains filtered or unexported methods
}

StrategyServer is the server API for Strategy service. All implementations must embed UnimplementedStrategyServer for forward compatibility

type TestTemplateReply

type TestTemplateReply struct {
	Msg string `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
	// contains filtered or unexported fields
}

测试hook模板响应参数

func (*TestTemplateReply) Descriptor deprecated

func (*TestTemplateReply) Descriptor() ([]byte, []int)

Deprecated: Use TestTemplateReply.ProtoReflect.Descriptor instead.

func (*TestTemplateReply) GetMsg

func (x *TestTemplateReply) GetMsg() string

func (*TestTemplateReply) ProtoMessage

func (*TestTemplateReply) ProtoMessage()

func (*TestTemplateReply) ProtoReflect

func (x *TestTemplateReply) ProtoReflect() protoreflect.Message

func (*TestTemplateReply) Reset

func (x *TestTemplateReply) Reset()

func (*TestTemplateReply) String

func (x *TestTemplateReply) String() string

func (*TestTemplateReply) Validate

func (m *TestTemplateReply) Validate() error

Validate checks the field values on TestTemplateReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*TestTemplateReply) ValidateAll

func (m *TestTemplateReply) ValidateAll() error

ValidateAll checks the field values on TestTemplateReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in TestTemplateReplyMultiError, or nil if none found.

type TestTemplateReplyMultiError

type TestTemplateReplyMultiError []error

TestTemplateReplyMultiError is an error wrapping multiple validation errors returned by TestTemplateReply.ValidateAll() if the designated constraints aren't met.

func (TestTemplateReplyMultiError) AllErrors

func (m TestTemplateReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TestTemplateReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type TestTemplateReplyValidationError

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

TestTemplateReplyValidationError is the validation error returned by TestTemplateReply.Validate if the designated constraints aren't met.

func (TestTemplateReplyValidationError) Cause

Cause function returns cause value.

func (TestTemplateReplyValidationError) Error

Error satisfies the builtin error interface

func (TestTemplateReplyValidationError) ErrorName

ErrorName returns error name.

func (TestTemplateReplyValidationError) Field

Field function returns field value.

func (TestTemplateReplyValidationError) Key

Key function returns key value.

func (TestTemplateReplyValidationError) Reason

Reason function returns reason value.

type TestTemplateRequest

type TestTemplateRequest struct {

	// APP
	NotifyType api.NotifyTemplateType `protobuf:"varint,2,opt,name=notifyType,proto3,enum=api.NotifyTemplateType" json:"notifyType,omitempty"`
	// 模板
	Template string `protobuf:"bytes,3,opt,name=template,proto3" json:"template,omitempty"`
	// 策略ID
	StrategyId uint32 `protobuf:"varint,4,opt,name=strategyId,proto3" json:"strategyId,omitempty"`
	// contains filtered or unexported fields
}

测试hook模板请求参数

func (*TestTemplateRequest) Descriptor deprecated

func (*TestTemplateRequest) Descriptor() ([]byte, []int)

Deprecated: Use TestTemplateRequest.ProtoReflect.Descriptor instead.

func (*TestTemplateRequest) GetNotifyType

func (x *TestTemplateRequest) GetNotifyType() api.NotifyTemplateType

func (*TestTemplateRequest) GetStrategyId

func (x *TestTemplateRequest) GetStrategyId() uint32

func (*TestTemplateRequest) GetTemplate

func (x *TestTemplateRequest) GetTemplate() string

func (*TestTemplateRequest) ProtoMessage

func (*TestTemplateRequest) ProtoMessage()

func (*TestTemplateRequest) ProtoReflect

func (x *TestTemplateRequest) ProtoReflect() protoreflect.Message

func (*TestTemplateRequest) Reset

func (x *TestTemplateRequest) Reset()

func (*TestTemplateRequest) String

func (x *TestTemplateRequest) String() string

func (*TestTemplateRequest) Validate

func (m *TestTemplateRequest) Validate() error

Validate checks the field values on TestTemplateRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*TestTemplateRequest) ValidateAll

func (m *TestTemplateRequest) ValidateAll() error

ValidateAll checks the field values on TestTemplateRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in TestTemplateRequestMultiError, or nil if none found.

type TestTemplateRequestMultiError

type TestTemplateRequestMultiError []error

TestTemplateRequestMultiError is an error wrapping multiple validation errors returned by TestTemplateRequest.ValidateAll() if the designated constraints aren't met.

func (TestTemplateRequestMultiError) AllErrors

func (m TestTemplateRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TestTemplateRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type TestTemplateRequestValidationError

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

TestTemplateRequestValidationError is the validation error returned by TestTemplateRequest.Validate if the designated constraints aren't met.

func (TestTemplateRequestValidationError) Cause

Cause function returns cause value.

func (TestTemplateRequestValidationError) Error

Error satisfies the builtin error interface

func (TestTemplateRequestValidationError) ErrorName

ErrorName returns error name.

func (TestTemplateRequestValidationError) Field

Field function returns field value.

func (TestTemplateRequestValidationError) Key

Key function returns key value.

func (TestTemplateRequestValidationError) Reason

Reason function returns reason value.

type UnimplementedStrategyServer

type UnimplementedStrategyServer struct {
}

UnimplementedStrategyServer must be embedded to have forward compatible implementations.

func (UnimplementedStrategyServer) BatchDeleteStrategy

func (UnimplementedStrategyServer) CreateStrategy

func (UnimplementedStrategyServer) DeleteStrategy

func (UnimplementedStrategyServer) ExportStrategy

func (UnimplementedStrategyServer) GetStrategy

func (UnimplementedStrategyServer) ListStrategy

func (UnimplementedStrategyServer) SelectStrategy

func (UnimplementedStrategyServer) TestNotifyTemplate

func (UnimplementedStrategyServer) UpdateStrategy

type UnsafeStrategyServer

type UnsafeStrategyServer interface {
	// contains filtered or unexported methods
}

UnsafeStrategyServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to StrategyServer will result in compilation errors.

type UpdateStrategyReply

type UpdateStrategyReply struct {

	// 策略ID, 成功返回策略ID
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

更新策略响应参数

func (*UpdateStrategyReply) Descriptor deprecated

func (*UpdateStrategyReply) Descriptor() ([]byte, []int)

Deprecated: Use UpdateStrategyReply.ProtoReflect.Descriptor instead.

func (*UpdateStrategyReply) GetId

func (x *UpdateStrategyReply) GetId() uint32

func (*UpdateStrategyReply) ProtoMessage

func (*UpdateStrategyReply) ProtoMessage()

func (*UpdateStrategyReply) ProtoReflect

func (x *UpdateStrategyReply) ProtoReflect() protoreflect.Message

func (*UpdateStrategyReply) Reset

func (x *UpdateStrategyReply) Reset()

func (*UpdateStrategyReply) String

func (x *UpdateStrategyReply) String() string

func (*UpdateStrategyReply) Validate

func (m *UpdateStrategyReply) Validate() error

Validate checks the field values on UpdateStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*UpdateStrategyReply) ValidateAll

func (m *UpdateStrategyReply) ValidateAll() error

ValidateAll checks the field values on UpdateStrategyReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in UpdateStrategyReplyMultiError, or nil if none found.

type UpdateStrategyReplyMultiError

type UpdateStrategyReplyMultiError []error

UpdateStrategyReplyMultiError is an error wrapping multiple validation errors returned by UpdateStrategyReply.ValidateAll() if the designated constraints aren't met.

func (UpdateStrategyReplyMultiError) AllErrors

func (m UpdateStrategyReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UpdateStrategyReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type UpdateStrategyReplyValidationError

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

UpdateStrategyReplyValidationError is the validation error returned by UpdateStrategyReply.Validate if the designated constraints aren't met.

func (UpdateStrategyReplyValidationError) Cause

Cause function returns cause value.

func (UpdateStrategyReplyValidationError) Error

Error satisfies the builtin error interface

func (UpdateStrategyReplyValidationError) ErrorName

ErrorName returns error name.

func (UpdateStrategyReplyValidationError) Field

Field function returns field value.

func (UpdateStrategyReplyValidationError) Key

Key function returns key value.

func (UpdateStrategyReplyValidationError) Reason

Reason function returns reason value.

type UpdateStrategyRequest

type UpdateStrategyRequest struct {

	// 策略ID, 路径参数, 必填, 大于0
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// 策略组ID, 所属的策略组ID信息, 可以替换成新的, 如果不替换则使用原有的
	GroupId uint32 `protobuf:"varint,2,opt,name=groupId,proto3" json:"groupId,omitempty"`
	// 告警名称, 必填, 字符串, 长度限制: 1-255, 正则表达式: ^[a-zA-Z0-9_]+$
	Alert string `protobuf:"bytes,3,opt,name=alert,proto3" json:"alert,omitempty"`
	// 表达式, 必填, promQL表达式
	Expr string `protobuf:"bytes,4,opt,name=expr,proto3" json:"expr,omitempty"`
	// 持续时间,(1s,1m,1h,1d), 对应prometheus的持续时间单位for
	Duration *api.Duration `protobuf:"bytes,5,opt,name=duration,proto3" json:"duration,omitempty"`
	// 标签, keys 长度限制: 1-32, 正则表达式: ^[a-zA-Z0-9_]+$
	Labels map[string]string `` /* 153-byte string literal not displayed */
	// 注解, keys 长度限制: 1-32, 正则表达式: ^[a-zA-Z0-9_]+$
	Annotations map[string]string `` /* 163-byte string literal not displayed */
	// 告警页面ID列表
	AlarmPageIds []uint32 `protobuf:"varint,8,rep,packed,name=alarmPageIds,proto3" json:"alarmPageIds,omitempty"`
	// 分类ID列表, 对应字典表ID
	CategoryIds []uint32 `protobuf:"varint,9,rep,packed,name=categoryIds,proto3" json:"categoryIds,omitempty"`
	// 告警级别ID, 对应字典表ID(告警等级维护在字典表中)
	AlarmLevelId uint32 `protobuf:"varint,10,opt,name=alarmLevelId,proto3" json:"alarmLevelId,omitempty"`
	// 备注, 长度限制: 0-255
	Remark string `protobuf:"bytes,11,opt,name=remark,proto3" json:"remark,omitempty"`
	// 数据源
	DataSourceId uint32 `protobuf:"varint,12,opt,name=dataSourceId,proto3" json:"dataSourceId,omitempty"`
	// 最大抑制时常
	MaxSuppress *api.Duration `protobuf:"bytes,13,opt,name=maxSuppress,proto3" json:"maxSuppress,omitempty"`
	// 告警通知间隔
	SendInterval *api.Duration `protobuf:"bytes,14,opt,name=sendInterval,proto3" json:"sendInterval,omitempty"`
	// 是否发送告警通知
	SendRecover bool `protobuf:"varint,15,opt,name=sendRecover,proto3" json:"sendRecover,omitempty"`
	// contains filtered or unexported fields
}

更新策略请求参数

func (*UpdateStrategyRequest) Descriptor deprecated

func (*UpdateStrategyRequest) Descriptor() ([]byte, []int)

Deprecated: Use UpdateStrategyRequest.ProtoReflect.Descriptor instead.

func (*UpdateStrategyRequest) GetAlarmLevelId

func (x *UpdateStrategyRequest) GetAlarmLevelId() uint32

func (*UpdateStrategyRequest) GetAlarmPageIds

func (x *UpdateStrategyRequest) GetAlarmPageIds() []uint32

func (*UpdateStrategyRequest) GetAlert

func (x *UpdateStrategyRequest) GetAlert() string

func (*UpdateStrategyRequest) GetAnnotations

func (x *UpdateStrategyRequest) GetAnnotations() map[string]string

func (*UpdateStrategyRequest) GetCategoryIds

func (x *UpdateStrategyRequest) GetCategoryIds() []uint32

func (*UpdateStrategyRequest) GetDataSourceId

func (x *UpdateStrategyRequest) GetDataSourceId() uint32

func (*UpdateStrategyRequest) GetDuration

func (x *UpdateStrategyRequest) GetDuration() *api.Duration

func (*UpdateStrategyRequest) GetExpr

func (x *UpdateStrategyRequest) GetExpr() string

func (*UpdateStrategyRequest) GetGroupId

func (x *UpdateStrategyRequest) GetGroupId() uint32

func (*UpdateStrategyRequest) GetId

func (x *UpdateStrategyRequest) GetId() uint32

func (*UpdateStrategyRequest) GetLabels

func (x *UpdateStrategyRequest) GetLabels() map[string]string

func (*UpdateStrategyRequest) GetMaxSuppress

func (x *UpdateStrategyRequest) GetMaxSuppress() *api.Duration

func (*UpdateStrategyRequest) GetRemark

func (x *UpdateStrategyRequest) GetRemark() string

func (*UpdateStrategyRequest) GetSendInterval

func (x *UpdateStrategyRequest) GetSendInterval() *api.Duration

func (*UpdateStrategyRequest) GetSendRecover

func (x *UpdateStrategyRequest) GetSendRecover() bool

func (*UpdateStrategyRequest) ProtoMessage

func (*UpdateStrategyRequest) ProtoMessage()

func (*UpdateStrategyRequest) ProtoReflect

func (x *UpdateStrategyRequest) ProtoReflect() protoreflect.Message

func (*UpdateStrategyRequest) Reset

func (x *UpdateStrategyRequest) Reset()

func (*UpdateStrategyRequest) String

func (x *UpdateStrategyRequest) String() string

func (*UpdateStrategyRequest) Validate

func (m *UpdateStrategyRequest) Validate() error

Validate checks the field values on UpdateStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*UpdateStrategyRequest) ValidateAll

func (m *UpdateStrategyRequest) ValidateAll() error

ValidateAll checks the field values on UpdateStrategyRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in UpdateStrategyRequestMultiError, or nil if none found.

type UpdateStrategyRequestMultiError

type UpdateStrategyRequestMultiError []error

UpdateStrategyRequestMultiError is an error wrapping multiple validation errors returned by UpdateStrategyRequest.ValidateAll() if the designated constraints aren't met.

func (UpdateStrategyRequestMultiError) AllErrors

func (m UpdateStrategyRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UpdateStrategyRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type UpdateStrategyRequestValidationError

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

UpdateStrategyRequestValidationError is the validation error returned by UpdateStrategyRequest.Validate if the designated constraints aren't met.

func (UpdateStrategyRequestValidationError) Cause

Cause function returns cause value.

func (UpdateStrategyRequestValidationError) Error

Error satisfies the builtin error interface

func (UpdateStrategyRequestValidationError) ErrorName

ErrorName returns error name.

func (UpdateStrategyRequestValidationError) Field

Field function returns field value.

func (UpdateStrategyRequestValidationError) Key

Key function returns key value.

func (UpdateStrategyRequestValidationError) Reason

Reason function returns reason value.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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