model

package
v0.1.32 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2023 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause Imports: 4 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActionRule added in v0.1.13

type ActionRule struct {

	// 规则名称
	RuleName string `json:"rule_name"`

	// 项目ID
	ProjectId string `json:"project_id"`

	// 子账号名称
	UserName string `json:"user_name"`

	// 规则描述
	Desc *string `json:"desc,omitempty"`

	// 规则类型。\"1\":通知,\"2\":用户
	Type ActionRuleType `json:"type"`

	// 消息模板
	NotificationTemplate string `json:"notification_template"`

	// 创建时间
	CreateTime *int64 `json:"create_time,omitempty"`

	// 修改时间
	UpdateTime *int64 `json:"update_time,omitempty"`

	// 时区
	TimeZone *string `json:"time_zone,omitempty"`

	// SMN主题信息,不能大于5
	SmnTopics []SmnTopics `json:"smn_topics"`
}

告警行动规则

func (ActionRule) String added in v0.1.13

func (o ActionRule) String() string

type ActionRuleType added in v0.1.19

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

func (ActionRuleType) MarshalJSON added in v0.1.19

func (c ActionRuleType) MarshalJSON() ([]byte, error)

func (*ActionRuleType) UnmarshalJSON added in v0.1.19

func (c *ActionRuleType) UnmarshalJSON(b []byte) error

func (ActionRuleType) Value added in v0.1.19

func (c ActionRuleType) Value() string

type ActionRuleTypeEnum added in v0.1.19

type ActionRuleTypeEnum struct {
	E_1 ActionRuleType
	E_2 ActionRuleType
}

func GetActionRuleTypeEnum added in v0.1.19

func GetActionRuleTypeEnum() ActionRuleTypeEnum

type AddActionRuleRequest added in v0.1.13

type AddActionRuleRequest struct {
	Body *ActionRule `json:"body,omitempty"`
}

Request Object

func (AddActionRuleRequest) String added in v0.1.13

func (o AddActionRuleRequest) String() string

type AddActionRuleResponse added in v0.1.13

type AddActionRuleResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (AddActionRuleResponse) String added in v0.1.13

func (o AddActionRuleResponse) String() string

type AddAlarmRuleRequest

type AddAlarmRuleRequest struct {
	Body *AlarmRuleParam `json:"body,omitempty"`
}

Request Object

func (AddAlarmRuleRequest) String

func (o AddAlarmRuleRequest) String() string

type AddAlarmRuleResponse

type AddAlarmRuleResponse struct {

	// 阈值规则id。
	AlarmRuleId    *int64 `json:"alarm_rule_id,omitempty"`
	HttpStatusCode int    `json:"-"`
}

Response Object

func (AddAlarmRuleResponse) String

func (o AddAlarmRuleResponse) String() string

type AddEvent2alarmRuleRequest added in v0.1.13

type AddEvent2alarmRuleRequest struct {
	Body *Event2alarmRuleBody `json:"body,omitempty"`
}

Request Object

func (AddEvent2alarmRuleRequest) String added in v0.1.13

func (o AddEvent2alarmRuleRequest) String() string

type AddEvent2alarmRuleResponse added in v0.1.13

type AddEvent2alarmRuleResponse struct {
	Body           *string `json:"body,omitempty"`
	HttpStatusCode int     `json:"-"`
}

Response Object

func (AddEvent2alarmRuleResponse) String added in v0.1.13

type AddMetricDataRequest

type AddMetricDataRequest struct {
	Body *[]MetricDataItem `json:"body,omitempty"`
}

Request Object

func (AddMetricDataRequest) String

func (o AddMetricDataRequest) String() string

type AddMetricDataResponse

type AddMetricDataResponse struct {

	// 响应码。
	ErrorCode *string `json:"errorCode,omitempty"`

	// 响应信息描述。
	ErrorMessage   *string `json:"errorMessage,omitempty"`
	HttpStatusCode int     `json:"-"`
}

Response Object

func (AddMetricDataResponse) String

func (o AddMetricDataResponse) String() string

type AddMuteRulesRequest added in v0.1.13

type AddMuteRulesRequest struct {
	Body *MuteRule `json:"body,omitempty"`
}

Request Object

func (AddMuteRulesRequest) String added in v0.1.13

func (o AddMuteRulesRequest) String() string

type AddMuteRulesResponse added in v0.1.13

type AddMuteRulesResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (AddMuteRulesResponse) String added in v0.1.13

func (o AddMuteRulesResponse) String() string

type AddOrUpdateServiceDiscoveryRulesRequest

type AddOrUpdateServiceDiscoveryRulesRequest struct {
	Body *AppRulesBody `json:"body,omitempty"`
}

Request Object

func (AddOrUpdateServiceDiscoveryRulesRequest) String

type AddOrUpdateServiceDiscoveryRulesResponse

type AddOrUpdateServiceDiscoveryRulesResponse struct {

	// 响应码。
	ErrorCode *string `json:"errorCode,omitempty"`

	// 响应信息描述。
	ErrorMessage *string `json:"errorMessage,omitempty"`

	// 响应状态码。
	ResponseStatus *int32 `json:"responseStatus,omitempty"`
	HttpStatusCode int    `json:"-"`
}

Response Object

func (AddOrUpdateServiceDiscoveryRulesResponse) String

type AlarmRuleParam

type AlarmRuleParam struct {

	// 是否启用通知。
	ActionEnabled *bool `json:"action_enabled,omitempty"`

	// 告警状态通知列表。
	AlarmActions *[]string `json:"alarm_actions,omitempty"`

	// 告警清除建议。
	AlarmAdvice *string `json:"alarm_advice,omitempty"`

	// 阈值规则描述。
	AlarmDescription *string `json:"alarm_description,omitempty"`

	// 告警级别。1:紧急,2:重要,3:一般,4:提示。
	AlarmLevel AlarmRuleParamAlarmLevel `json:"alarm_level"`

	// 阈值规则名称。
	AlarmRuleName string `json:"alarm_rule_name"`

	// 超限条件。
	ComparisonOperator string `json:"comparison_operator"`

	// 时间序列维度。
	Dimensions []Dimension `json:"dimensions"`

	// 间隔周期。
	EvaluationPeriods int32 `json:"evaluation_periods"`

	// 阈值规则是否启用。
	IdTurnOn *bool `json:"id_turn_on,omitempty"`

	// 数据不足通知列表。
	InsufficientDataActions *[]string `json:"insufficient_data_actions,omitempty"`

	// 时间序列名称。名称长度取值范围为1~255个字符。
	MetricName string `json:"metric_name"`

	// 时间序列命名空间。
	Namespace string `json:"namespace"`

	// 正常状态通知列表。
	OkActions *[]string `json:"ok_actions,omitempty"`

	// 统计周期。
	Period int32 `json:"period"`

	// 统计方式。
	Statistic AlarmRuleParamStatistic `json:"statistic"`

	// 超限值。
	Threshold string `json:"threshold"`

	// 时间序列单位
	Unit string `json:"unit"`
}

阈值规则实体

func (AlarmRuleParam) String

func (o AlarmRuleParam) String() string

type AlarmRuleParamAlarmLevel added in v0.1.13

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

func (AlarmRuleParamAlarmLevel) MarshalJSON added in v0.1.13

func (c AlarmRuleParamAlarmLevel) MarshalJSON() ([]byte, error)

func (*AlarmRuleParamAlarmLevel) UnmarshalJSON added in v0.1.13

func (c *AlarmRuleParamAlarmLevel) UnmarshalJSON(b []byte) error

func (AlarmRuleParamAlarmLevel) Value added in v0.1.13

func (c AlarmRuleParamAlarmLevel) Value() int32

type AlarmRuleParamAlarmLevelEnum added in v0.1.13

type AlarmRuleParamAlarmLevelEnum struct {
	E_1 AlarmRuleParamAlarmLevel
	E_2 AlarmRuleParamAlarmLevel
	E_3 AlarmRuleParamAlarmLevel
	E_4 AlarmRuleParamAlarmLevel
}

func GetAlarmRuleParamAlarmLevelEnum added in v0.1.13

func GetAlarmRuleParamAlarmLevelEnum() AlarmRuleParamAlarmLevelEnum

type AlarmRuleParamStatistic added in v0.1.13

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

func (AlarmRuleParamStatistic) MarshalJSON added in v0.1.13

func (c AlarmRuleParamStatistic) MarshalJSON() ([]byte, error)

func (*AlarmRuleParamStatistic) UnmarshalJSON added in v0.1.13

func (c *AlarmRuleParamStatistic) UnmarshalJSON(b []byte) error

func (AlarmRuleParamStatistic) Value added in v0.1.13

func (c AlarmRuleParamStatistic) Value() string

type AlarmRuleParamStatisticEnum added in v0.1.13

type AlarmRuleParamStatisticEnum struct {
	MAXIMUM      AlarmRuleParamStatistic
	MINIMUM      AlarmRuleParamStatistic
	AVERAGE      AlarmRuleParamStatistic
	SUM          AlarmRuleParamStatistic
	SAMPLE_COUNT AlarmRuleParamStatistic
}

func GetAlarmRuleParamStatisticEnum added in v0.1.13

func GetAlarmRuleParamStatisticEnum() AlarmRuleParamStatisticEnum

type AppNameRule

type AppNameRule struct {

	// 取值类型。 从cmdLineHash、cmdLine、env、str里面选取。
	NameType string `json:"nameType"`

	// 输入值。
	Args []string `json:"args"`

	// 服务名(仅nameType为cmdLineHash时填写)。
	Value *[]string `json:"value,omitempty"`
}

服务命名部分,数组中有多个对象时表示将每个对象抽取到的字符串拼接作为服务的名称。 nameType取值cmdLine时args格式为[\"start\",\"end\"],表示抽取命令行中start、end之间的字符。 nameType取值cmdLine时args格式为[\"aa\"],表示抽取环境变量名为aa对应的环境变量值。 nameType取值str时,args格式为[\"fix\"],表示服务名称最后拼接固定文字fix。 nameType取值cmdLineHash时,args格式为[\"0001\"],value格式为[\"ser\"],表示当启动命令是0001时,服务名称为ser。

func (AppNameRule) String

func (o AppNameRule) String() string

type AppRules

type AppRules struct {

	// 规则创建时间(创建时不传,修改时传查询返回的createTime)。
	CreateTime *string `json:"createTime,omitempty"`

	// true、false 规则是否启用。
	Enable bool `json:"enable"`

	// aom_inventory_rules_event 规则事件名称,对于服务发现固定 为\"aom_inventory_rules_event\"。
	EventName string `json:"eventName"`

	// 主机ID(暂不使用,传空即可)。
	Hostid *[]string `json:"hostid,omitempty"`

	// 创建时填空,修改时填规则ID。
	Id string `json:"id"`

	// 规则名称。 字符长度小于64位,以小写字母(a-z)开头,只能包含0-9/a-z/-,不能以-结尾。
	Name string `json:"name"`

	// 租户从IAM申请到的projectid,一般为32位字符串。
	Projectid string `json:"projectid"`

	Spec *AppRulesSpec `json:"spec"`
}

服务参数。

func (AppRules) String

func (o AppRules) String() string

type AppRulesBody

type AppRulesBody struct {

	// 服务参数。
	AppRules *[]AppRules `json:"appRules,omitempty"`
}

func (AppRulesBody) String

func (o AppRulesBody) String() string

type AppRulesSpec

type AppRulesSpec struct {

	// 服务类型,用于标记服务的分类,仅用于规则分类和界面展示。可以填写任意字段,如按技术栈分类可填写Java,Python。按作用分类可填写collector(采集),database(数据库)等。
	AppType string `json:"appType"`

	// 属性列表(暂不使用,可不传)。 cmdLine、env
	AttrList *[]string `json:"attrList,omitempty"`

	// 是否开启日志采集。 true、false
	DetectLog string `json:"detectLog"`

	// 规则发现部分,数组中有多个对象时表示需要同时满足所有条件的进程才会被匹配到。 checkType为cmdLine时checkMode填contain,checkContent格式为[“xxx”]表示进程命令行参数中需要包含xxx。checkType为env时checkMode填contain,checkContent格式为 [\"k1\",\"v1\"]表示进程环境变量中需要包含名为k1值为v1的环境变量。checkType为scope时checkMode填equals,checkContent格式为节点ID数组[\"hostId1”,”hostId2”],表示规则仅会在这些节点上生效(如果不指定节点范围,规则将下发到该项目所有的节点)。
	DiscoveryRule []DiscoveryRule `json:"discoveryRule"`

	// 是否为默认规则。 true、false
	IsDefaultRule string `json:"isDefaultRule"`

	// 是否为规则预探测场景(预探测场景不会保存规则,仅用于规则下发之前验证该规则能否有效发现节点上的进程)。 true、false
	IsDetect string `json:"isDetect"`

	// 日志文件的后缀。 log、trace、out
	LogFileFix []string `json:"logFileFix"`

	// 日志路径配置规则。 当cmdLineHash为固定字符串时,指定日志路径或者日志文件。否则只采集进程当前打开的以.log和.trace结尾的文件。nameType取值cmdLineHash时,args格式为[\"00001\"],value格式为[\"/xxx/xx.log\"],表示当启动命令是00001时,日志路径为/xxx/xx.log。
	LogPathRule *[]LogPathRule `json:"logPathRule,omitempty"`

	NameRule *NameRule `json:"nameRule"`

	// 规则优先级。 1~9999的整数字符串,默认取值为9999
	Priority int32 `json:"priority"`
}

规则详情。

func (AppRulesSpec) String

func (o AppRulesSpec) String() string

type ApplicationNameRule

type ApplicationNameRule struct {

	// 取值类型。 从cmdLineHash、cmdLine、env、str里面选取。
	NameType string `json:"nameType"`

	// 输入值。
	Args []string `json:"args"`

	// 服务名(仅nameType为cmdLineHash时填写)。
	Value *[]string `json:"value,omitempty"`
}

应用命名部分。 nameType取值cmdLine时args格式为[\"start\",\"end\"],表示抽取命令行中start、end之间的字符。 nameType取值cmdLine时args格式为 [\"aa\"],表示抽取环境变量名为aa对应的环境变量值。 nameType取值str时,args格式为[\"fix\"],表示服务名称最后拼接固定文字fix。 nameType取值cmdLineHash时,args格式为[\"0001\"],value格式为[\"ser\"],表示当启动命令是0001时,应用名称为ser。

func (ApplicationNameRule) String

func (o ApplicationNameRule) String() string

type CountEventsRequest

type CountEventsRequest struct {

	// 查询类型。type=active_alert代表查询活动告警,type=history_alert代表查询历史告警。不传或者传其他值则返回指定查询条件的所有信息。
	Type *CountEventsRequestType `json:"type,omitempty"`

	Body *EventQueryParam `json:"body,omitempty"`
}

Request Object

func (CountEventsRequest) String

func (o CountEventsRequest) String() string

type CountEventsRequestType

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

func (CountEventsRequestType) MarshalJSON

func (c CountEventsRequestType) MarshalJSON() ([]byte, error)

func (*CountEventsRequestType) UnmarshalJSON

func (c *CountEventsRequestType) UnmarshalJSON(b []byte) error

func (CountEventsRequestType) Value added in v0.0.90

func (c CountEventsRequestType) Value() string

type CountEventsRequestTypeEnum

type CountEventsRequestTypeEnum struct {
	HISTORY_ALERT CountEventsRequestType
	ACTIVE_ALERT  CountEventsRequestType
}

func GetCountEventsRequestTypeEnum

func GetCountEventsRequestTypeEnum() CountEventsRequestTypeEnum

type CountEventsResponse

type CountEventsResponse struct {

	// 统计步长。毫秒数,例如一分钟则填写为60000。
	Step *int64 `json:"step,omitempty"`

	// 统计结果对应的时间序列。
	Timestamps *[]int64 `json:"timestamps,omitempty"`

	// 事件或者告警不同级别相同时间序列对应的统计结果。
	Series         *[]EventSeries `json:"series,omitempty"`
	HttpStatusCode int            `json:"-"`
}

Response Object

func (CountEventsResponse) String

func (o CountEventsResponse) String() string

type DeleteActionRuleRequest added in v0.1.13

type DeleteActionRuleRequest struct {
	Body *[]string `json:"body,omitempty"`
}

Request Object

func (DeleteActionRuleRequest) String added in v0.1.13

func (o DeleteActionRuleRequest) String() string

type DeleteActionRuleResponse added in v0.1.13

type DeleteActionRuleResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (DeleteActionRuleResponse) String added in v0.1.13

func (o DeleteActionRuleResponse) String() string

type DeleteAlarmRuleRequest

type DeleteAlarmRuleRequest struct {

	// 阈值规则ID。
	AlarmRuleId string `json:"alarm_rule_id"`
}

Request Object

func (DeleteAlarmRuleRequest) String

func (o DeleteAlarmRuleRequest) String() string

type DeleteAlarmRuleResponse

type DeleteAlarmRuleResponse struct {
	Body           *string `json:"body,omitempty"`
	HttpStatusCode int     `json:"-"`
}

Response Object

func (DeleteAlarmRuleResponse) String

func (o DeleteAlarmRuleResponse) String() string

type DeleteAlarmRulesBody

type DeleteAlarmRulesBody struct {

	// 阈值规则列表
	AlarmRules []string `json:"alarm_rules"`
}

func (DeleteAlarmRulesBody) String

func (o DeleteAlarmRulesBody) String() string

type DeleteAlarmRulesRequest

type DeleteAlarmRulesRequest struct {
	Body *DeleteAlarmRulesBody `json:"body,omitempty"`
}

Request Object

func (DeleteAlarmRulesRequest) String

func (o DeleteAlarmRulesRequest) String() string

type DeleteAlarmRulesResponse

type DeleteAlarmRulesResponse struct {
	Body           *string `json:"body,omitempty"`
	HttpStatusCode int     `json:"-"`
}

Response Object

func (DeleteAlarmRulesResponse) String

func (o DeleteAlarmRulesResponse) String() string

type DeleteEvent2alarmRuleRequest added in v0.1.13

type DeleteEvent2alarmRuleRequest struct {
	Body *[]string `json:"body,omitempty"`
}

Request Object

func (DeleteEvent2alarmRuleRequest) String added in v0.1.13

type DeleteEvent2alarmRuleResponse added in v0.1.13

type DeleteEvent2alarmRuleResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (DeleteEvent2alarmRuleResponse) String added in v0.1.13

type DeleteMuteRuleName added in v0.1.13

type DeleteMuteRuleName struct {

	// 要删除的静默规则的名称
	Name string `json:"name"`
}

要删除的规则名称

func (DeleteMuteRuleName) String added in v0.1.13

func (o DeleteMuteRuleName) String() string

type DeleteMuteRulesRequest added in v0.1.13

type DeleteMuteRulesRequest struct {
	Body *[]DeleteMuteRuleName `json:"body,omitempty"`
}

Request Object

func (DeleteMuteRulesRequest) String added in v0.1.13

func (o DeleteMuteRulesRequest) String() string

type DeleteMuteRulesResponse added in v0.1.13

type DeleteMuteRulesResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (DeleteMuteRulesResponse) String added in v0.1.13

func (o DeleteMuteRulesResponse) String() string

type DeleteserviceDiscoveryRulesRequest

type DeleteserviceDiscoveryRulesRequest struct {

	// 发现规则ID,传多个时以逗号分隔。
	AppRulesIds []string `json:"appRulesIds"`
}

Request Object

func (DeleteserviceDiscoveryRulesRequest) String

type DeleteserviceDiscoveryRulesResponse

type DeleteserviceDiscoveryRulesResponse struct {

	// 响应码。
	ErrorCode *string `json:"errorCode,omitempty"`

	// 响应信息描述。
	ErrorMessage *string `json:"errorMessage,omitempty"`

	// 响应状态码。
	ResponseStatus *int32 `json:"responseStatus,omitempty"`
	HttpStatusCode int    `json:"-"`
}

Response Object

func (DeleteserviceDiscoveryRulesResponse) String

type Dimension

type Dimension struct {

	// 维度名称。
	Name string `json:"name"`

	// 维度取值。
	Value string `json:"value"`
}

指标维度。

func (Dimension) String

func (o Dimension) String() string

type Dimension2

type Dimension2 struct {

	// 维度名称。
	Name string `json:"name"`

	// 指标数据的值。
	Value string `json:"value"`
}

指标维度参数

func (Dimension2) String

func (o Dimension2) String() string

type DimensionSeries

type DimensionSeries struct {

	// 维度名称。
	Name *string `json:"name,omitempty"`

	// 维度取值。
	Value *string `json:"value,omitempty"`
}

时间序列维度列表。

func (DimensionSeries) String

func (o DimensionSeries) String() string

type DiscoveryRule

type DiscoveryRule struct {

	// 匹配值。
	CheckContent []string `json:"checkContent"`

	// 匹配条件。 contain、equals
	CheckMode string `json:"checkMode"`

	// 匹配类型。 cmdLine、env、scope
	CheckType string `json:"checkType"`
}

规则发现部分,数组中有多个对象时表示需要同时满足所有条件的进程才会被匹配到。 checkType为cmdLine时checkMode填contain,checkContent格式为[“xxx”]表示进程命令行参数中需要包含xxx。checkType为env时checkMode填contain,checkContent格式为 [\"k1\",\"v1\"]表示进程环境变量中需要包含名为k1值为v1的环境变量。checkType为scope时checkMode填equals,checkContent格式为节点ID数组[\"hostId1”,”hostId2”],表示规则仅会在这些节点上生效(如果不指定节点范围,规则将下发到该项目所有的节点)。

func (DiscoveryRule) String

func (o DiscoveryRule) String() string

type Event2alarmRuleBody added in v0.1.13

type Event2alarmRuleBody struct {

	// 用户项目id
	UserId string `json:"user_id"`

	// 规则名称
	Name string `json:"name"`

	// 规则描述
	Description *string `json:"description,omitempty"`

	// 创建时间
	CreateTime int32 `json:"create_time"`

	// 更新时间
	UpdateTime *int32 `json:"update_time,omitempty"`

	// 事件源
	ResourceProvider *string `json:"resource_provider,omitempty"`

	Metadata *Event2alarmRuleBodyMetadata `json:"metadata"`

	// 规则是否启用
	Enable bool `json:"enable"`

	// 触发策略
	TriggerPolicies []Event2alarmRuleBodyTriggerPolicies `json:"trigger_policies"`

	// 告警类型
	AlarmType string `json:"alarm_type"`

	// 告警行动规则
	ActionRule string `json:"action_rule"`

	// 告警抑制规则
	InhibitRule *string `json:"inhibit_rule,omitempty"`

	// 告警静默规则
	RouteGroupRule *string `json:"route_group_rule,omitempty"`
}

事件类告警实体

func (Event2alarmRuleBody) String added in v0.1.13

func (o Event2alarmRuleBody) String() string

type Event2alarmRuleBodyMetadata added in v0.1.13

type Event2alarmRuleBodyMetadata struct {

	// 用户自定义标签
	CustomField *[]string `json:"customField,omitempty"`
}

源数据

func (Event2alarmRuleBodyMetadata) String added in v0.1.13

type Event2alarmRuleBodyTriggerPolicies added in v0.1.13

type Event2alarmRuleBodyTriggerPolicies struct {

	// 自增编号
	Id *int32 `json:"id,omitempty"`

	// 事件名称
	Name *string `json:"name,omitempty"`

	// 触发类型
	TriggerType *Event2alarmRuleBodyTriggerPoliciesTriggerType `json:"trigger_type,omitempty"`

	// 触发周期
	Period *int32 `json:"period,omitempty"`

	// 比较符
	Operator *string `json:"operator,omitempty"`

	// 触发次数
	Count *int32 `json:"count,omitempty"`

	// 告警等级
	Level *string `json:"level,omitempty"`
}

func (Event2alarmRuleBodyTriggerPolicies) String added in v0.1.13

type Event2alarmRuleBodyTriggerPoliciesTriggerType added in v0.1.19

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

func (Event2alarmRuleBodyTriggerPoliciesTriggerType) MarshalJSON added in v0.1.19

func (*Event2alarmRuleBodyTriggerPoliciesTriggerType) UnmarshalJSON added in v0.1.19

func (Event2alarmRuleBodyTriggerPoliciesTriggerType) Value added in v0.1.19

type Event2alarmRuleBodyTriggerPoliciesTriggerTypeEnum added in v0.1.19

type Event2alarmRuleBodyTriggerPoliciesTriggerTypeEnum struct {
	ACCUMULATIVE Event2alarmRuleBodyTriggerPoliciesTriggerType
	NOTIFICATION Event2alarmRuleBodyTriggerPoliciesTriggerType
}

func GetEvent2alarmRuleBodyTriggerPoliciesTriggerTypeEnum added in v0.1.19

func GetEvent2alarmRuleBodyTriggerPoliciesTriggerTypeEnum() Event2alarmRuleBodyTriggerPoliciesTriggerTypeEnum

type EventList

type EventList struct {

	// 事件或者告警详情。
	Events []EventModel `json:"events"`
}

事件告警上报实体。

func (EventList) String

func (o EventList) String() string

type EventModel

type EventModel struct {

	// 事件或者告警产生的时间,CST毫秒级时间戳。
	StartsAt *int64 `json:"starts_at,omitempty"`

	// 事件或者告警清除的时间,CST毫秒级时间戳,为0时表示未删除。
	EndsAt *int64 `json:"ends_at,omitempty"`

	// 告警自动清除时间。毫秒数,例如一分钟则填写为60000。默认清除时间为3天,对应数字为 4320 * 1000(即:3天 * 24小时 * 60分钟 * 1000毫秒)。
	Timeout *int64 `json:"timeout,omitempty"`

	// 事件或者告警的详细信息,为键值对形式。必须字段为: - event_name:事件或者告警名称,类型为String; - event_severity:事件级别枚举值。类型为String,四种类型 \"Critical\", \"Major\", \"Minor\", \"Info\"; - event_type:事件类别枚举值。类型为String,event为普通告警,alarm为告警事件; - resource_provider:事件对应云服务名称。类型为String; - resource_type:事件对应资源类型。类型为String; - resource_id:事件对应资源信息。类型为String。
	Metadata *interface{} `json:"metadata,omitempty"`

	// 事件或者告警附加字段,可以为空。
	Annotations *interface{} `json:"annotations,omitempty"`

	// 事件或者告警预留字段,为空。
	AttachRule *interface{} `json:"attach_rule,omitempty"`

	// 事件或者告警id,系统会自动生成,上报无须填写该字段。
	Id *string `json:"id,omitempty"`
}

事件或者告警元数据。

func (EventModel) String

func (o EventModel) String() string

type EventQueryParam

type EventQueryParam struct {

	// timeRange用于指标查询时间范围,主要用于解决客户端时间和服务端时间不一致情况下,查询最近N分钟的数据。另可用于精确查询某一段时间的数据。  如:  - -1.-1.60(表示最近60分钟),不管当前客户端是什么时间,都以服务端时间为准查询最近60分钟。 - 1650852000000.1650852300000.5(表示北京时间2022-04-25 10:00:00至2022-04-25 10:05:00指定的5分钟)  格式:  startTimeInMillis.endTimeInMillis.durationInMinutes  参数解释:  - startTimeInMillis: 查询的开始时间,格式为UTC毫秒,如果指定为-1,服务端将按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如-1.1650852300000.5,则相当于1650852000000.1650852300000.5 - endTimeInMillis: 查询的结束时间,格式为UTC毫秒,如果指定为-1,服务端将按(startTimeInMillis + durationInMinutes * 60 * 1000)计算结束时间,如果计算出的结束时间大于当前系统时间,则使用当前系统时间。如1650852000000.-1.5,则相当于1650852000000.1650852300000.5 - durationInMinutes:查询时间的跨度分钟数。 取值范围大于0并且大于等于(endTimeInMillis - startTimeInMillis) / (60 * 1000) - 1。当开始时间与结束时间都设置为-1时,系统会将结束时间设置为当前时间UTC毫秒值,并按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如:-1.-1.60(表示最近60分钟)  约束:  单次请求中,查询时长与周期需要满足以下条件: durationInMinutes * 60 / period <= 1440
	TimeRange string `json:"time_range"`

	// 统计步长。毫秒数,例如一分钟则填写为60000。
	Step int64 `json:"step"`

	// 模糊查询匹配字段,可以为空。如果值不为空,可以模糊匹配metadata字段中的必选字段的值。
	Search *string `json:"search,omitempty"`

	Sort *EventQueryParamSort `json:"sort,omitempty"`

	// 查询条件组合,可以为空。
	MetadataRelation *[]RelationModel `json:"metadata_relation,omitempty"`
}

查询事件或者告警信息 。

func (EventQueryParam) String

func (o EventQueryParam) String() string

type EventQueryParam2

type EventQueryParam2 struct {

	// timeRange用于指标查询时间范围,主要用于解决客户端时间和服务端时间不一致情况下,查询最近N分钟的数据。另可用于精确查询某一段时间的数据。  如:  - -1.-1.60(表示最近60分钟),不管当前客户端是什么时间,都以服务端时间为准查询最近60分钟。 - 1650852000000.1650852300000.5(表示北京时间2022-04-25 10:00:00至2022-04-25 10:05:00指定的5分钟)  格式:  startTimeInMillis.endTimeInMillis.durationInMinutes  参数解释:  - startTimeInMillis: 查询的开始时间,格式为UTC毫秒,如果指定为-1,服务端将按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如-1.1650852300000.5,则相当于1650852000000.1650852300000.5 - endTimeInMillis: 查询的结束时间,格式为UTC毫秒,如果指定为-1,服务端将按(startTimeInMillis + durationInMinutes * 60 * 1000)计算结束时间,如果计算出的结束时间大于当前系统时间,则使用当前系统时间。如1650852000000.-1.5,则相当于1650852000000.1650852300000.5 - durationInMinutes:查询时间的跨度分钟数。 取值范围大于0并且大于等于(endTimeInMillis - startTimeInMillis) / (60 * 1000) - 1。当开始时间与结束时间都设置为-1时,系统会将结束时间设置为当前时间UTC毫秒值,并按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如:-1.-1.60(表示最近60分钟)  约束:  单次请求中,查询时长与周期需要满足以下条件: durationInMinutes * 60 / period <= 1440
	TimeRange string `json:"time_range"`

	// 统计步长。毫秒数,例如一分钟则填写为60000。
	Step *int64 `json:"step,omitempty"`

	// 模糊查询匹配字段,可以为空。如果值不为空,可以模糊匹配。metadata字段为必选字段。
	Search *string `json:"search,omitempty"`

	Sort *EventQueryParam2Sort `json:"sort,omitempty"`

	// 查询条件组合,可以为空。
	MetadataRelation *[]RelationModel `json:"metadata_relation,omitempty"`
}

查询事件或者告警信息 。

func (EventQueryParam2) String

func (o EventQueryParam2) String() string

type EventQueryParam2Sort added in v0.0.76

type EventQueryParam2Sort struct {

	// 排序字段列表。会根据列表中定义顺序对返回列表最排序。
	OrderBy *[]string `json:"order_by,omitempty"`

	// 排序方式枚举值。asc代表正序,desc代表倒叙。
	Order *EventQueryParam2SortOrder `json:"order,omitempty"`
}

返回列表的排序方式,可以为空。

func (EventQueryParam2Sort) String added in v0.0.76

func (o EventQueryParam2Sort) String() string

type EventQueryParam2SortOrder added in v0.0.76

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

func (EventQueryParam2SortOrder) MarshalJSON added in v0.0.76

func (c EventQueryParam2SortOrder) MarshalJSON() ([]byte, error)

func (*EventQueryParam2SortOrder) UnmarshalJSON added in v0.0.76

func (c *EventQueryParam2SortOrder) UnmarshalJSON(b []byte) error

func (EventQueryParam2SortOrder) Value added in v0.0.90

type EventQueryParam2SortOrderEnum added in v0.0.76

type EventQueryParam2SortOrderEnum struct {
	ASC  EventQueryParam2SortOrder
	DESC EventQueryParam2SortOrder
}

func GetEventQueryParam2SortOrderEnum added in v0.0.76

func GetEventQueryParam2SortOrderEnum() EventQueryParam2SortOrderEnum

type EventQueryParamSort

type EventQueryParamSort struct {

	// 排序字段列表。会根据列表中定义顺序对返回列表进行排序。
	OrderBy *[]string `json:"order_by,omitempty"`

	// 排序方式枚举值。asc代表正序,desc代表倒叙。
	Order *EventQueryParamSortOrder `json:"order,omitempty"`
}

返回列表的排序方式,可以为空。

func (EventQueryParamSort) String

func (o EventQueryParamSort) String() string

type EventQueryParamSortOrder

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

func (EventQueryParamSortOrder) MarshalJSON

func (c EventQueryParamSortOrder) MarshalJSON() ([]byte, error)

func (*EventQueryParamSortOrder) UnmarshalJSON

func (c *EventQueryParamSortOrder) UnmarshalJSON(b []byte) error

func (EventQueryParamSortOrder) Value added in v0.0.90

func (c EventQueryParamSortOrder) Value() string

type EventQueryParamSortOrderEnum

type EventQueryParamSortOrderEnum struct {
	ASC  EventQueryParamSortOrder
	DESC EventQueryParamSortOrder
}

func GetEventQueryParamSortOrderEnum

func GetEventQueryParamSortOrderEnum() EventQueryParamSortOrderEnum

type EventSeries

type EventSeries struct {

	// 事件或者告警级别枚举类型。
	EventSeverity *EventSeriesEventSeverity `json:"event_severity,omitempty"`

	// 事件或者告警统计结果。
	Values *[]int32 `json:"values,omitempty"`
}

事件或者告警统计值统计结果元数据。

func (EventSeries) String

func (o EventSeries) String() string

type EventSeriesEventSeverity

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

func (EventSeriesEventSeverity) MarshalJSON

func (c EventSeriesEventSeverity) MarshalJSON() ([]byte, error)

func (*EventSeriesEventSeverity) UnmarshalJSON

func (c *EventSeriesEventSeverity) UnmarshalJSON(b []byte) error

func (EventSeriesEventSeverity) Value added in v0.0.90

func (c EventSeriesEventSeverity) Value() string

type EventSeriesEventSeverityEnum

type EventSeriesEventSeverityEnum struct {
	CRITICAL EventSeriesEventSeverity
	MAJOR    EventSeriesEventSeverity
	MINOR    EventSeriesEventSeverity
	INFO     EventSeriesEventSeverity
}

func GetEventSeriesEventSeverityEnum

func GetEventSeriesEventSeverityEnum() EventSeriesEventSeverityEnum

type ListActionRuleRequest added in v0.1.13

type ListActionRuleRequest struct {
}

Request Object

func (ListActionRuleRequest) String added in v0.1.13

func (o ListActionRuleRequest) String() string

type ListActionRuleResponse added in v0.1.13

type ListActionRuleResponse struct {

	// 告警行动规则列表
	ActionRules    *[]ActionRule `json:"action_rules,omitempty"`
	HttpStatusCode int           `json:"-"`
}

Response Object

func (ListActionRuleResponse) String added in v0.1.13

func (o ListActionRuleResponse) String() string

type ListAlarmRuleRequest

type ListAlarmRuleRequest struct {

	// 分页信息。
	Offset *string `json:"offset,omitempty"`

	// 用于限制结果数据条数。 取值范围(0,1000],默认值为1000。
	Limit *int32 `json:"limit,omitempty"`
}

Request Object

func (ListAlarmRuleRequest) String

func (o ListAlarmRuleRequest) String() string

type ListAlarmRuleResponse

type ListAlarmRuleResponse struct {
	MetaData *MetaData `json:"meta_data,omitempty"`

	Thresholds     *[]QueryAlarmResult `json:"thresholds,omitempty"`
	HttpStatusCode int                 `json:"-"`
}

Response Object

func (ListAlarmRuleResponse) String

func (o ListAlarmRuleResponse) String() string

type ListEvent2alarmRuleRequest added in v0.1.13

type ListEvent2alarmRuleRequest struct {
}

Request Object

func (ListEvent2alarmRuleRequest) String added in v0.1.13

type ListEvent2alarmRuleResponse added in v0.1.13

type ListEvent2alarmRuleResponse struct {
	Body           *[]Event2alarmRuleBody `json:"body,omitempty"`
	HttpStatusCode int                    `json:"-"`
}

Response Object

func (ListEvent2alarmRuleResponse) String added in v0.1.13

type ListEventsRequest

type ListEventsRequest struct {

	// 查询类型。type=active_alert代表查询活动告警,type=history_alert代表查询历史告警。不传或者传其他值则返回指定查询条件的所有信息。
	Type *ListEventsRequestType `json:"type,omitempty"`

	Body *EventQueryParam2 `json:"body,omitempty"`
}

Request Object

func (ListEventsRequest) String

func (o ListEventsRequest) String() string

type ListEventsRequestType

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

func (ListEventsRequestType) MarshalJSON

func (c ListEventsRequestType) MarshalJSON() ([]byte, error)

func (*ListEventsRequestType) UnmarshalJSON

func (c *ListEventsRequestType) UnmarshalJSON(b []byte) error

func (ListEventsRequestType) Value added in v0.0.90

func (c ListEventsRequestType) Value() string

type ListEventsRequestTypeEnum

type ListEventsRequestTypeEnum struct {
	HISTORY_ALERT ListEventsRequestType
	ACTIVE_ALERT  ListEventsRequestType
}

func GetListEventsRequestTypeEnum

func GetListEventsRequestTypeEnum() ListEventsRequestTypeEnum

type ListEventsResponse

type ListEventsResponse struct {

	// 事件或者告警详情。
	Events         *[]EventModel `json:"events,omitempty"`
	HttpStatusCode int           `json:"-"`
}

Response Object

func (ListEventsResponse) String

func (o ListEventsResponse) String() string

type ListInstantQueryAomPromGetRequest

type ListInstantQueryAomPromGetRequest struct {

	// PromQL表达式(参考https://prometheus.io/docs/prometheus/latest/querying/basics/)。
	Query string `json:"query"`

	// 指定用于计算 PromQL 的时间戳,(Unix时间戳格式,单位:秒)。
	Time *string `json:"time,omitempty"`
}

Request Object

func (ListInstantQueryAomPromGetRequest) String

type ListInstantQueryAomPromGetResponse

type ListInstantQueryAomPromGetResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 响应数据。
	Data           *interface{} `json:"data,omitempty"`
	HttpStatusCode int          `json:"-"`
}

Response Object

func (ListInstantQueryAomPromGetResponse) String

type ListInstantQueryAomPromPostRequest

type ListInstantQueryAomPromPostRequest struct {

	// PromQL表达式(参考https://prometheus.io/docs/prometheus/latest/querying/basics/)。
	Query string `json:"query"`

	// 指定用于计算 PromQL 的时间戳,(Unix时间戳格式,单位:秒)。
	Time *string `json:"time,omitempty"`
}

Request Object

func (ListInstantQueryAomPromPostRequest) String

type ListInstantQueryAomPromPostResponse

type ListInstantQueryAomPromPostResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 响应数据。
	Data           *interface{} `json:"data,omitempty"`
	HttpStatusCode int          `json:"-"`
}

Response Object

func (ListInstantQueryAomPromPostResponse) String

type ListLabelValuesAomPromGetRequest

type ListLabelValuesAomPromGetRequest struct {

	// 查询所用标签。
	LabelName string `json:"label_name"`
}

Request Object

func (ListLabelValuesAomPromGetRequest) String

type ListLabelValuesAomPromGetResponse

type ListLabelValuesAomPromGetResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 标签值信息。
	Data           *[]string `json:"data,omitempty"`
	HttpStatusCode int       `json:"-"`
}

Response Object

func (ListLabelValuesAomPromGetResponse) String

type ListLabelsAomPromGetRequest

type ListLabelsAomPromGetRequest struct {
}

Request Object

func (ListLabelsAomPromGetRequest) String

type ListLabelsAomPromGetResponse

type ListLabelsAomPromGetResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 标签值信息。
	Data           *[]string `json:"data,omitempty"`
	HttpStatusCode int       `json:"-"`
}

Response Object

func (ListLabelsAomPromGetResponse) String

type ListLabelsAomPromPostRequest

type ListLabelsAomPromPostRequest struct {
}

Request Object

func (ListLabelsAomPromPostRequest) String

type ListLabelsAomPromPostResponse

type ListLabelsAomPromPostResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 标签值信息。
	Data           *[]string `json:"data,omitempty"`
	HttpStatusCode int       `json:"-"`
}

Response Object

func (ListLabelsAomPromPostResponse) String

type ListLogItemsRequest

type ListLogItemsRequest struct {

	// 日志接口调用方式,当值为\"querylogs\"时接口功能为查询日志内容。
	Type string `json:"type"`

	Body *QueryBodyParam `json:"body,omitempty"`
}

Request Object

func (ListLogItemsRequest) String

func (o ListLogItemsRequest) String() string

type ListLogItemsResponse

type ListLogItemsResponse struct {

	// 响应码,SVCSTG_AMS_2000000代表正常返回。
	ErrorCode *string `json:"errorCode,omitempty"`

	// 响应信息描述。
	ErrorMessage *string `json:"errorMessage,omitempty"`

	// 查询结果元数据信息,包括返回总数及结果。
	Result         *string `json:"result,omitempty"`
	HttpStatusCode int     `json:"-"`
}

Response Object

func (ListLogItemsResponse) String

func (o ListLogItemsResponse) String() string

type ListMetadataAomPromGetRequest

type ListMetadataAomPromGetRequest struct {
}

Request Object

func (ListMetadataAomPromGetRequest) String

type ListMetadataAomPromGetResponse

type ListMetadataAomPromGetResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 元数据信息。
	Data           *interface{} `json:"data,omitempty"`
	HttpStatusCode int          `json:"-"`
}

Response Object

func (ListMetadataAomPromGetResponse) String

type ListMetricItemsRequest

type ListMetricItemsRequest struct {

	// 指标查询方式。
	Type *string `json:"type,omitempty"`

	// 用于限制本次返回的结果数据条数。 取值范围(0,1000],默认值为1000。
	Limit *string `json:"limit,omitempty"`

	// 分页查询起始位置,为非负整数。
	Start *string `json:"start,omitempty"`

	Body *MetricApiQueryItemParam `json:"body,omitempty"`
}

Request Object

func (ListMetricItemsRequest) String

func (o ListMetricItemsRequest) String() string

type ListMetricItemsResponse

type ListMetricItemsResponse struct {
	MetaData *MetaData `json:"metaData,omitempty"`

	// 指标对象列表。
	Metrics        *[]MetricItemResultApi `json:"metrics,omitempty"`
	HttpStatusCode int                    `json:"-"`
}

Response Object

func (ListMetricItemsResponse) String

func (o ListMetricItemsResponse) String() string

type ListMuteRuleRequest added in v0.1.13

type ListMuteRuleRequest struct {
}

Request Object

func (ListMuteRuleRequest) String added in v0.1.13

func (o ListMuteRuleRequest) String() string

type ListMuteRuleResponse added in v0.1.13

type ListMuteRuleResponse struct {
	Body           *[]MuteRule `json:"body,omitempty"`
	HttpStatusCode int         `json:"-"`
}

Response Object

func (ListMuteRuleResponse) String added in v0.1.13

func (o ListMuteRuleResponse) String() string

type ListNotifiedHistoriesRequest added in v0.1.13

type ListNotifiedHistoriesRequest struct {

	// 告警流水号
	EventSn *string `json:"event_sn,omitempty"`
}

Request Object

func (ListNotifiedHistoriesRequest) String added in v0.1.13

type ListNotifiedHistoriesResponse added in v0.1.13

type ListNotifiedHistoriesResponse struct {

	// 告警流水号
	EventSn *string `json:"event_sn,omitempty"`

	// 通知结果
	Notifications  *[]Notifications `json:"notifications,omitempty"`
	HttpStatusCode int              `json:"-"`
}

Response Object

func (ListNotifiedHistoriesResponse) String added in v0.1.13

type ListRangeQueryAomPromGetRequest

type ListRangeQueryAomPromGetRequest struct {

	// PromQL表达式(参考https://prometheus.io/docs/prometheus/latest/querying/basics/)。
	Query string `json:"query"`

	// 起始时间戳(Unix时间戳格式,单位:秒)。
	Start string `json:"start"`

	// 结束时间戳(Unix时间戳格式,单位:秒)。
	End string `json:"end"`

	// 查询时间步长,时间区内每step秒执行一次。
	Step string `json:"step"`
}

Request Object

func (ListRangeQueryAomPromGetRequest) String

type ListRangeQueryAomPromGetResponse

type ListRangeQueryAomPromGetResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 响应数据。
	Data           *interface{} `json:"data,omitempty"`
	HttpStatusCode int          `json:"-"`
}

Response Object

func (ListRangeQueryAomPromGetResponse) String

type ListRangeQueryAomPromPostRequest

type ListRangeQueryAomPromPostRequest struct {

	// PromQL表达式(参考https://prometheus.io/docs/prometheus/latest/querying/basics/)。
	Query string `json:"query"`

	// 起始时间戳(Unix时间戳格式,单位:秒)。
	Start string `json:"start"`

	// 结束时间戳(Unix时间戳格式,单位:秒)。
	End string `json:"end"`

	// 查询时间步长,时间区内每step秒执行一次。
	Step string `json:"step"`
}

Request Object

func (ListRangeQueryAomPromPostRequest) String

type ListRangeQueryAomPromPostResponse

type ListRangeQueryAomPromPostResponse struct {

	// 响应状态。
	Status *string `json:"status,omitempty"`

	// 响应数据。
	Data           *interface{} `json:"data,omitempty"`
	HttpStatusCode int          `json:"-"`
}

Response Object

func (ListRangeQueryAomPromPostResponse) String

type ListSampleRequest

type ListSampleRequest struct {

	// 用于对查询到的时序数据进行断点插值,默认值为-1。 -1:断点处使用-1进行表示。 0 :断点处使用0进行表示。 null:断点处使用null进行表示。 average:断点处使用前后邻近的有效数据的平均值进行表示,如果不存在有效数据则使用null进行表示。
	FillValue *string `json:"fill_value,omitempty"`

	Body *QuerySampleParam `json:"body,omitempty"`
}

Request Object

func (ListSampleRequest) String

func (o ListSampleRequest) String() string

type ListSampleResponse

type ListSampleResponse struct {

	// 时间序列对象列表。
	Samples        *[]SampleDataValue `json:"samples,omitempty"`
	HttpStatusCode int                `json:"-"`
}

Response Object

func (ListSampleResponse) String

func (o ListSampleResponse) String() string

type ListSeriesRequest

type ListSeriesRequest struct {

	// 用于限制本次返回的结果数据条数。 取值范围(0,1000],默认值为1000。
	Limit *string `json:"limit,omitempty"`

	// 分页查询起始位置,为非负整数。
	Offset *string `json:"offset,omitempty"`

	Body *SeriesApiQueryItemParam `json:"body,omitempty"`
}

Request Object

func (ListSeriesRequest) String

func (o ListSeriesRequest) String() string

type ListSeriesResponse

type ListSeriesResponse struct {

	// 时间序列对象列表。
	Series *[]SeriesQueryItemResult `json:"series,omitempty"`

	MetaData       *MetaDataSeries `json:"meta_data,omitempty"`
	HttpStatusCode int             `json:"-"`
}

Response Object

func (ListSeriesResponse) String

func (o ListSeriesResponse) String() string

type ListServiceDiscoveryRulesRequest

type ListServiceDiscoveryRulesRequest struct {

	// 具体的服务发现规则ID,可以精确匹配到一条服务发现规则。不传时返回project下所有服务发现规则的列表。
	Id *string `json:"id,omitempty"`
}

Request Object

func (ListServiceDiscoveryRulesRequest) String

type ListServiceDiscoveryRulesResponse

type ListServiceDiscoveryRulesResponse struct {

	// 查询结果规则信息。
	AppRules *[]AppRules `json:"appRules,omitempty"`

	// 响应码,AOM_INVENTORY_2000000代表正常返回。
	ErrorCode *string `json:"errorCode,omitempty"`

	// 响应信息描述。
	ErrorMessage   *string `json:"errorMessage,omitempty"`
	HttpStatusCode int     `json:"-"`
}

Response Object

func (ListServiceDiscoveryRulesResponse) String

type LogPathRule

type LogPathRule struct {

	// 命令行。
	Args []string `json:"args"`

	// 取值类型。 cmdLineHash
	NameType string `json:"nameType"`

	// 日志路径。
	Value []string `json:"value"`
}

日志路径配置规则。 当cmdLineHash为固定字符串时,指定日志路径或者日志文件。否则只采集进程当前打开的以.log和.trace结尾的文件。nameType取值cmdLineHash时,args格式为[\"00001\"],value格式为[\"/xxx/xx.log\"],表示当启动命令是00001时,日志路径为/xxx/xx.log。

func (LogPathRule) String

func (o LogPathRule) String() string

type Match added in v0.1.13

type Match struct {

	// 指定按照Metadata中的key进行匹配
	Key string `json:"key"`

	// 指定匹配的方式:EXIST:存在,REGEX:正则,EQUALS:等于
	Operate MatchOperate `json:"operate"`

	// 要匹配的key对应的value,当operate为存在时,此值为空
	Value *[]string `json:"value,omitempty"`
}

静默规则的匹配条件

func (Match) String added in v0.1.13

func (o Match) String() string

type MatchOperate added in v0.1.13

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

func (MatchOperate) MarshalJSON added in v0.1.13

func (c MatchOperate) MarshalJSON() ([]byte, error)

func (*MatchOperate) UnmarshalJSON added in v0.1.13

func (c *MatchOperate) UnmarshalJSON(b []byte) error

func (MatchOperate) Value added in v0.1.13

func (c MatchOperate) Value() string

type MatchOperateEnum added in v0.1.13

type MatchOperateEnum struct {
	EQUALS MatchOperate
	REGEX  MatchOperate
	EXIST  MatchOperate
}

func GetMatchOperateEnum added in v0.1.13

func GetMatchOperateEnum() MatchOperateEnum

type MetaData

type MetaData struct {

	// 当前返回结果条数。
	Count *int32 `json:"count,omitempty"`

	// 下一个开始的标记,用于分页,null表示无更多数据。
	Start *int64 `json:"start,omitempty"`

	// 总条数。
	Total *int32 `json:"total,omitempty"`
}

查询结果元数据信息,包括分页信息等。

func (MetaData) String

func (o MetaData) String() string

type MetaDataSeries

type MetaDataSeries struct {

	// 当前返回结果条数。
	Count *int32 `json:"count,omitempty"`

	// 下一个开始的标记,用于分页,null表示无更多数据。
	Offset *int32 `json:"offset,omitempty"`

	// 总条数。
	Total *int32 `json:"total,omitempty"`

	// 偏移量。
	NextToken *int32 `json:"nextToken,omitempty"`
}

查询结果元数据信息,包括分页信息等。

func (MetaDataSeries) String

func (o MetaDataSeries) String() string

type MetricApiQueryItemParam

type MetricApiQueryItemParam struct {

	// 资源编号,格式为resType_resId。其中resType部分的枚举值为:host, application, instance, container, process, network, storage, volume。当URI参数中的type取值为“inventory”时,通过该参数查询关联的指标,不再使用metricItems数组中的信息。
	InventoryId *string `json:"inventoryId,omitempty"`

	// 当URI参数中的type取值不为“inventory”时,就通过该数组传递的参数信息进行指标查询。
	MetricItems *[]QueryMetricItemOptionParam `json:"metricItems,omitempty"`
}

指标查询参数详情。

func (MetricApiQueryItemParam) String

func (o MetricApiQueryItemParam) String() string

type MetricDataItem

type MetricDataItem struct {

	// 数据收集时间支持过去1天和未来半小时范围内的数据上报。数据收集时间需要满足:  当前UTC时间减去collect_time小于等于24小时或者collect_time减去当前UTC时间小于等于30分钟。  若数据上报时间早于当天8点,则指标监控页面只显示当天8点后的数据。 取值范围: UNIX时间戳,单位毫秒。
	CollectTime int64 `json:"collect_time"`

	Metric *MetricItemInfo `json:"metric"`

	// 指标数据的值。
	Values []ValueData `json:"values"`
}

指标

func (MetricDataItem) String

func (o MetricDataItem) String() string

type MetricDataPoints

type MetricDataPoints struct {

	// 统计方式。
	Statistics *[]StatisticValue `json:"statistics,omitempty"`

	// 时间戳。
	Timestamp *int64 `json:"timestamp,omitempty"`

	// 时间序列单位。
	Unit *string `json:"unit,omitempty"`
}

查询重点指标。

func (MetricDataPoints) String

func (o MetricDataPoints) String() string

type MetricDataValue

type MetricDataValue struct {

	// 重点指标。
	DataPoints *[]MetricDataPoints `json:"dataPoints,omitempty"`

	Metric *MetricQueryMeritcParam `json:"metric,omitempty"`
}

查询结果详细。

func (MetricDataValue) String

func (o MetricDataValue) String() string

type MetricItemInfo

type MetricItemInfo struct {

	// 指标维度列表。 维度最多允许50个,单个维度为json对象,结构说明如下 dimension.name:长度最短为1,最大为32。 dimension.value:长度最短为1,最大为64。
	Dimensions []Dimension2 `json:"dimensions"`

	// 指标命名空间。 namespace中不允许存在\":\"符号,取值范围 格式为service.item;service和item必须是字符串,必须以字母开头,只能包含0-9/a-z/A-Z/_,总长度最短为3,最大为32,service不能为“PAAS”。
	Namespace string `json:"namespace"`
}

指标详细信息。

func (MetricItemInfo) String

func (o MetricItemInfo) String() string

type MetricItemResultApi

type MetricItemResultApi struct {

	// 指标维度列表。
	Dimensions *[]Dimension `json:"dimensions,omitempty"`

	// 指标哈希值。
	Dimensionvaluehash *string `json:"dimensionvaluehash,omitempty"`

	// 指标名称。
	MetricName *string `json:"metricName,omitempty"`

	// 命名空间。
	Namespace *string `json:"namespace,omitempty"`

	// 指标单位。
	Unit *string `json:"unit,omitempty"`
}

维度信息。

func (MetricItemResultApi) String

func (o MetricItemResultApi) String() string

type MetricQueryMeritcParam

type MetricQueryMeritcParam struct {

	// 指标维度列表。 取值范围: 数组不能为空,同时数组中任何一个dimension对象name和value属性的值也不能为空。
	Dimensions []Dimension `json:"dimensions"`

	// 指标名称。名称长度取值范围为1~255个字符。 取值范围: AOM提供的基础指标, cpuUsage、cpuCoreUsed等 cpuUage:cpu使用率; cpuCoreUsed:cpu内核占用; 用户上报的自定义指标名称。
	MetricName string `json:"metricName"`

	// 指标命名空间。 取值范围: PAAS.CONTAINER:组件指标、实例指标、进程指标和容器指标的命名空间, PAAS.NODE: 主机指标、网络指标、磁盘指标和文件系统指标的命名空间, PAAS.SLA:SLA指标的命名空间, PAAS.AGGR:集群指标的命名空间, CUSTOMMETRICS:默认的自定义指标的命名空间。
	Namespace string `json:"namespace"`
}

查询参数集

func (MetricQueryMeritcParam) String

func (o MetricQueryMeritcParam) String() string

type MuteConfig added in v0.1.13

type MuteConfig struct {

	// 静默规则结束时间
	EndsAt *int64 `json:"ends_at,omitempty"`

	// 当type为每周或者每月时,scope不能为空
	Scope *[]string `json:"scope,omitempty"`

	// 静默规则开始时间
	StartsAt int64 `json:"starts_at"`

	// 静默规则生效时间种类。FIXED:固定方式统计,DAILY:按日合计,WEEKLY:按周统计,MONTHLY:按月统计
	Type MuteConfigType `json:"type"`
}

静默规则的生效时间配置

func (MuteConfig) String added in v0.1.13

func (o MuteConfig) String() string

type MuteConfigType added in v0.1.13

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

func (MuteConfigType) MarshalJSON added in v0.1.13

func (c MuteConfigType) MarshalJSON() ([]byte, error)

func (*MuteConfigType) UnmarshalJSON added in v0.1.13

func (c *MuteConfigType) UnmarshalJSON(b []byte) error

func (MuteConfigType) Value added in v0.1.13

func (c MuteConfigType) Value() string

type MuteConfigTypeEnum added in v0.1.13

type MuteConfigTypeEnum struct {
	FIXED   MuteConfigType
	DAILY   MuteConfigType
	WEEKLY  MuteConfigType
	MONTHLY MuteConfigType
}

func GetMuteConfigTypeEnum added in v0.1.13

func GetMuteConfigTypeEnum() MuteConfigTypeEnum

type MuteRule added in v0.1.13

type MuteRule struct {

	// 创建时间
	CreateTime *int64 `json:"create_time,omitempty"`

	// 规则描述
	Desc *string `json:"desc,omitempty"`

	// 规则的匹配条件
	Match [][]Match `json:"match"`

	MuteConfig *MuteConfig `json:"mute_config"`

	// 规则名称
	Name string `json:"name"`

	// 时区
	Timezone string `json:"timezone"`

	// 修改时间
	UpdateTime *int64 `json:"update_time,omitempty"`

	// 用户ID
	UserId *string `json:"user_id,omitempty"`
}

静默规则

func (MuteRule) String added in v0.1.13

func (o MuteRule) String() string

type NameRule

type NameRule struct {

	// 服务命名部分,数组中有多个对象时表示将每个对象抽取到的字符串拼接作为服务的名称。 nameType取值cmdLine时args格式为[\"start\",\"end\"],表示抽取命令行中start、end之间的字符。 nameType取值cmdLine时args格式为[\"aa\"],表示抽取环境变量名为aa对应的环境变量值。 nameType取值str时,args格式为[\"fix\"],表示服务名称最后拼接固定文字fix。 nameType取值cmdLineHash时,args格式为[\"0001\"],value格式为[\"ser\"],表示当启动命令是0001时,服务名称为ser。
	AppNameRule []AppNameRule `json:"appNameRule"`

	// 应用命名部分。 nameType取值cmdLine时args格式为[\"start\",\"end\"],表示抽取命令行中start、end之间的字符。 nameType取值cmdLine时args格式为 [\"aa\"],表示抽取环境变量名为aa对应的环境变量值。 nameType取值str时,args格式为[\"fix\"],表示服务名称最后拼接固定文字fix。 nameType取值cmdLineHash时,args格式为[\"0001\"],value格式为[\"ser\"],表示当启动命令是0001时,应用名称为ser。
	ApplicationNameRule []ApplicationNameRule `json:"applicationNameRule"`
}

服务发现规则命名部分。

func (NameRule) String

func (o NameRule) String() string

type Notifications added in v0.1.13

type Notifications struct {

	// 告警行动规则名称
	ActionRule *string `json:"action_rule,omitempty"`

	// 通知类型。SMN:消息通知服务
	NotifierChannel *NotificationsNotifierChannel `json:"notifier_channel,omitempty"`

	SmnChannel *SmnResponse `json:"smn_channel,omitempty"`
}

发送结果

func (Notifications) String added in v0.1.13

func (o Notifications) String() string

type NotificationsNotifierChannel added in v0.1.13

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

func (NotificationsNotifierChannel) MarshalJSON added in v0.1.13

func (c NotificationsNotifierChannel) MarshalJSON() ([]byte, error)

func (*NotificationsNotifierChannel) UnmarshalJSON added in v0.1.13

func (c *NotificationsNotifierChannel) UnmarshalJSON(b []byte) error

func (NotificationsNotifierChannel) Value added in v0.1.13

type NotificationsNotifierChannelEnum added in v0.1.13

type NotificationsNotifierChannelEnum struct {
	SMN NotificationsNotifierChannel
}

func GetNotificationsNotifierChannelEnum added in v0.1.13

func GetNotificationsNotifierChannelEnum() NotificationsNotifierChannelEnum

type PushEventsRequest

type PushEventsRequest struct {

	// 告警所属的企业项目id。
	XEnterprisePrjectId *string `json:"x-enterprise-prject-id,omitempty"`

	// 接口请求动作。action=clear代表清除告警,不传或者传其他值默认为上报动作。
	Action *PushEventsRequestAction `json:"action,omitempty"`

	Body *EventList `json:"body,omitempty"`
}

Request Object

func (PushEventsRequest) String

func (o PushEventsRequest) String() string

type PushEventsRequestAction

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

func (PushEventsRequestAction) MarshalJSON

func (c PushEventsRequestAction) MarshalJSON() ([]byte, error)

func (*PushEventsRequestAction) UnmarshalJSON

func (c *PushEventsRequestAction) UnmarshalJSON(b []byte) error

func (PushEventsRequestAction) Value added in v0.0.90

func (c PushEventsRequestAction) Value() string

type PushEventsRequestActionEnum

type PushEventsRequestActionEnum struct {
	CLEAR PushEventsRequestAction
}

func GetPushEventsRequestActionEnum

func GetPushEventsRequestActionEnum() PushEventsRequestActionEnum

type PushEventsResponse

type PushEventsResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (PushEventsResponse) String

func (o PushEventsResponse) String() string

type QueryAlarmResult

type QueryAlarmResult struct {

	// 是否启用通知。
	ActionEnabled *bool `json:"action_enabled,omitempty"`

	// 告警状态通知列表。
	AlarmActions *[]string `json:"alarm_actions,omitempty"`

	// 告警清除建议。
	AlarmAdvice *string `json:"alarm_advice,omitempty"`

	// 阈值规则描述。
	AlarmDescription *string `json:"alarm_description,omitempty"`

	// 告警级别。
	AlarmLevel *string `json:"alarm_level,omitempty"`

	// 阈值规则ID。
	AlarmRuleId *string `json:"alarm_rule_id,omitempty"`

	// 阈值规则名称。
	AlarmRuleName *string `json:"alarm_rule_name,omitempty"`

	// 极限条件。
	ComparisonOperator *string `json:"comparison_operator,omitempty"`

	// 时间序列维度。
	Dimensions *[]Dimension `json:"dimensions,omitempty"`

	// 间隔周期。
	EvaluationPeriods *int32 `json:"evaluation_periods,omitempty"`

	// 阈值规则是否启用。
	IdTurnOn *bool `json:"id_turn_on,omitempty"`

	// 数据不足通知列表。
	InsufficientDataActions *[]string `json:"insufficient_data_actions,omitempty"`

	// 时间序列名称。
	MetricName *string `json:"metric_name,omitempty"`

	// 时间序列命名空间。
	Namespace *string `json:"namespace,omitempty"`

	// 正常状态通知列表。
	OkActions *[]string `json:"ok_actions,omitempty"`

	// 统计周期。
	Period *int32 `json:"period,omitempty"`

	// 阈值规则模板名称。
	PolicyName *string `json:"policy_name,omitempty"`

	// 资源信息(已废弃)。
	Resources *[]string `json:"resources,omitempty"`

	// 原因描述。
	StateReason *string `json:"state_reason,omitempty"`

	// 状态更新时间戳。
	StateUpdatedTimestamp *string `json:"state_updated_timestamp,omitempty"`

	// 服务状态。
	StateValue *string `json:"state_value,omitempty"`

	// 统计方式。
	Statistic *string `json:"statistic,omitempty"`

	// 临界值。
	Threshold *string `json:"threshold,omitempty"`

	// 阈值规则类型。
	Type *string `json:"type,omitempty"`

	// 阈值单元。
	Unit *string `json:"unit,omitempty"`
}

阈值规则查询参数。

func (QueryAlarmResult) String

func (o QueryAlarmResult) String() string

type QueryBodyParam

type QueryBodyParam struct {

	// 取值范围 app_log,node _log,custom_log 日志类型字段:app_log:应用日志 node_log:主机日志 custom_log:自定义配置路径日志。
	Category string `json:"category"`

	// 搜索结束时间(UTC时间,毫秒级)。
	EndTime int64 `json:"endTime"`

	// 取值范围 0、1 。搜索时是否隐藏系统日志,默认0为隐藏1为显示。
	HideSyslog *int32 `json:"hideSyslog,omitempty"`

	// 1.支持关键词精确搜索。关键词指相邻两个分词符之间的单词。 2.支持关键词模糊匹配搜索,例如输入“RROR”或“ERRO?”或“*ROR*”或“ERR*”或“ER*OR”。 3.支持短语精确搜索,例如输入“Start to refresh alm Statistic”。 4.支持关键词的“与”、“或”组合搜索。格式为“query&&logs”或“query||logs”。 说明: 当前默认分词符有  , '\";=()[]{}@&<>/:\\n\\t\\r
	KeyWord *string `json:"keyWord,omitempty"`

	// 日志单行序列号第一次查询时不需要此参数,后续分页查询时需要使用可从上次查询的返回信息中获取.
	LineNum *string `json:"lineNum,omitempty"`

	// 表示每次查询的日志条数不填时默认为5000,建议您设置为100。 第一次查询时使用pageSize 后续分页查询时使用size。
	PageSizeSize *string `json:"pageSize/size,omitempty"`

	SearchKey *SearchKey `json:"searchKey"`

	// 搜索起始时间(UTC时间,毫秒级)。
	StartTime int64 `json:"startTime"`

	// 表示此次查询为分页查询,第一次查询时不需要此参数,后续分页查询时需要使用。
	Type *string `json:"type,omitempty"`

	// 标识按照lineNum升序查询还是降序查询。  true:降序(lineNum由大到小:时间从新到老)。  false:升序(lineNum由小到大:即时间从老到新)。
	IsDesc *bool `json:"isDesc,omitempty"`
}

func (QueryBodyParam) String

func (o QueryBodyParam) String() string

type QueryMetricDataParam

type QueryMetricDataParam struct {

	// 指标对象列表。 取值范围 JSON数组大小不超过20
	Metrics []MetricQueryMeritcParam `json:"metrics"`

	// 监控数据粒度。 取值范围(枚举):60(表示粒度为1分钟),300(表示粒度为5分钟),900(表示粒度为15分钟),3600(表示粒度为1小时)。
	Period int32 `json:"period"`

	// 统计方式。 取值范围 maximum,minimum,sum,average,sampleCount
	Statistics []string `json:"statistics"`

	// timeRange用于指标查询时间范围,主要用于解决客户端时间和服务端时间不一致情况下,查询最近N分钟的数据。另可用于精确查询某一段时间的数据。  如:  - -1.-1.60(表示最近60分钟),不管当前客户端是什么时间,都以服务端时间为准查询最近60分钟。  - 1650852000000.1650852300000.5(表示北京时间2022-04-25 10:00:00至2022-04-25 10:05:00指定的5分钟)  格式:  startTimeInMillis.endTimeInMillis.durationInMinutes  参数解释:  - startTimeInMillis: 查询的开始时间,格式为UTC毫秒,如果指定为-1,服务端将按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如-1.1650852300000.5,则相当于1650852000000.1650852300000.5  - endTimeInMillis: 查询的结束时间,格式为UTC毫秒,如果指定为-1,服务端将按(startTimeInMillis + durationInMinutes * 60 * 1000)计算结束时间,如果计算出的结束时间大于当前系统时间,则使用当前系统时间。如1650852000000.-1.5,则相当于1650852000000.1650852300000.5  - durationInMinutes:查询时间的跨度分钟数。 取值范围大于0并且大于等于(endTimeInMillis - startTimeInMillis) / (60 * 1000) - 1。当开始时间与结束时间都设置为-1时,系统会将结束时间设置为当前时间UTC毫秒值,并按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如:-1.-1.60(表示最近60分钟)  约束:  单次请求中,查询时长与周期需要满足以下条件: durationInMinutes * 60 / period <= 1440
	Timerange string `json:"timerange"`
}

该参数用来指定需要查询的数据维度,数据周期等。

func (QueryMetricDataParam) String

func (o QueryMetricDataParam) String() string

type QueryMetricItemOptionParam

type QueryMetricItemOptionParam struct {

	// 指标维度列表。
	Dimensions *[]Dimension `json:"dimensions,omitempty"`

	// 指标名称。名称长度取值范围为1~255个字符。 取值范围:AOM提供的基础指标,cpuUsage、cpuCoreUsed等。 cpuUage:cpu使用率; cpuCoreUsed:cpu内核占用; 用户上报的自定义指标名称。
	MetricName *string `json:"metricName,omitempty"`

	// 指标命名空间。 取值范围 PAAS.CONTAINER:组件指标、实例指标、进程指标和容器指标的命名空间, PAAS.NODE: 主机指标、网络指标、磁盘指标和文件系统指标的命名空间, PAAS.SLA:SLA指标的命名空间, PAAS.AGGR:集群指标的命名空间, CUSTOMMETRICS:默认的自定义指标的命名空间。
	Namespace QueryMetricItemOptionParamNamespace `json:"namespace"`
}

参数项。

func (QueryMetricItemOptionParam) String

type QueryMetricItemOptionParamNamespace

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

func (QueryMetricItemOptionParamNamespace) MarshalJSON

func (c QueryMetricItemOptionParamNamespace) MarshalJSON() ([]byte, error)

func (*QueryMetricItemOptionParamNamespace) UnmarshalJSON

func (c *QueryMetricItemOptionParamNamespace) UnmarshalJSON(b []byte) error

func (QueryMetricItemOptionParamNamespace) Value added in v0.0.90

type QuerySample

type QuerySample struct {

	// 时间序列命名空间。 取值范围: PAAS.CONTAINER、PAAS.NODE、PAAS.SLA、PAAS.AGGR、CUSTOMMETRICS等。 PAAS.CONTAINER:应用时间序列命名空间;  PAAS.NODE:节点时间序列命名空间;  PAAS.SLA:SLA时间序列命名空间;  PAAS.AGGR:集群时间序列命名空间;  CUSTOMMETRICS:自定义时间序列命名空间。
	Namespace string `json:"namespace"`

	// 时间序列维度列表。 可通过/v2/{project_id}/series接口中namespace+metric_name,查询当前监控的时间序列名称的时间序列维度列表。
	Dimensions []DimensionSeries `json:"dimensions"`

	// 时间序列名称。名称长度取值范围为1~255个字符。 取值范围: AOM提供的基础时间序列名称,cpuUsage、cpuCoreUsed等, cpuUage:cpu使用率; cpuCoreUsed:cpu内核占用; 用户上报的自定义时间序列名称。
	MetricName string `json:"metric_name"`
}

查询参数集。

func (QuerySample) String

func (o QuerySample) String() string

type QuerySampleParam

type QuerySampleParam struct {

	// 时序数据对象列表。  取值范围:JSON数组大小不超过20。
	Samples []QuerySample `json:"samples"`

	// 统计方式。 取值范围: maximum,minimum,sum,average,sampleCount。
	Statistics []string `json:"statistics"`

	// 监控数据粒度。 取值范围(枚举):60(表示粒度为1分钟),300(表示粒度为5分钟),900(表示粒度为15分钟),3600(表示粒度为1小时)。
	Period int32 `json:"period"`

	// timeRange用于指标查询时间范围,主要用于解决客户端时间和服务端时间不一致情况下,查询最近N分钟的数据。另可用于精确查询某一段时间的数据。  如:  - -1.-1.60(表示最近60分钟),不管当前客户端是什么时间,都以服务端时间为准查询最近60分钟。  - 1650852000000.1650852300000.5(表示北京时间2022-04-25 10:00:00至2022-04-25 10:05:00指定的5分钟)  格式:  startTimeInMillis.endTimeInMillis.durationInMinutes  参数解释:  - startTimeInMillis: 查询的开始时间,格式为UTC毫秒,如果指定为-1,服务端将按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如-1.1650852300000.5,则相当于1650852000000.1650852300000.5  - endTimeInMillis: 查询的结束时间,格式为UTC毫秒,如果指定为-1,服务端将按(startTimeInMillis + durationInMinutes * 60 * 1000)计算结束时间,如果计算出的结束时间大于当前系统时间,则使用当前系统时间。如1650852000000.-1.5,则相当于1650852000000.1650852300000.5  - durationInMinutes:查询时间的跨度分钟数。 取值范围大于0并且大于等于(endTimeInMillis - startTimeInMillis) / (60 * 1000) - 1。当开始时间与结束时间都设置为-1时,系统会将结束时间设置为当前时间UTC毫秒值,并按(endTimeInMillis - durationInMinutes * 60 * 1000)计算开始时间。如:-1.-1.60(表示最近60分钟)  约束:  单次请求中,查询时长与周期需要满足以下条件: durationInMinutes * 60 / period <= 1440
	TimeRange string `json:"time_range"`
}

时序数据查询参数。

func (QuerySampleParam) String

func (o QuerySampleParam) String() string

type QuerySeriesOptionParam

type QuerySeriesOptionParam struct {

	// 时间序列命名空间。 取值范围:PAAS.CONTAINER、PAAS.NODE、PAAS.SLA、PAAS.AGGR、CUSTOMMETRICS等。 PAAS.CONTAINER:应用时间序列命名空间; PAAS.NODE:节点时间序列命名空间; PAAS.SLA:SLA时间序列命名空间; PAAS.AGGR:集群时间序列命名空间; CUSTOMMETRICS:自定义时间序列命名空间。
	Namespace string `json:"namespace"`

	// 时间序列名称,名称长度取值范围为1~255个字符。 取值范围: AOM提供的基础时间序列名称,cpuUsage、cpuCoreUsed等: cpuUage:cpu使用率; cpuCoreUsed:cpu内核占用; 用户上报的自定义时间序列名称。
	MetricName *string `json:"metric_name,omitempty"`

	// 时间序列维度列表。 可通过/v2/{project_id}/series接口中namespace+metric_name, 查询当前监控的时间序列名称的时间序列维度列表。
	Dimensions *[]DimensionSeries `json:"dimensions,omitempty"`
}

参数项。

func (QuerySeriesOptionParam) String

func (o QuerySeriesOptionParam) String() string

type RelationModel

type RelationModel struct {

	// 指定查询字段的key,对应metadata里面的key 。
	Key *string `json:"key,omitempty"`

	// 查询条件中指定key的值。
	Value *[]string `json:"value,omitempty"`

	// 该条件与其他条件的组合方式。 AND:必须满足所有条件; OR:可以满足其中一个条件; NOT:必须不满足所有条件。
	Relation *RelationModelRelation `json:"relation,omitempty"`
}

查询条件。

func (RelationModel) String

func (o RelationModel) String() string

type RelationModelRelation

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

func (RelationModelRelation) MarshalJSON

func (c RelationModelRelation) MarshalJSON() ([]byte, error)

func (*RelationModelRelation) UnmarshalJSON

func (c *RelationModelRelation) UnmarshalJSON(b []byte) error

func (RelationModelRelation) Value added in v0.0.90

func (c RelationModelRelation) Value() string

type RelationModelRelationEnum

type RelationModelRelationEnum struct {
	AND RelationModelRelation
	OR  RelationModelRelation
	NOT RelationModelRelation
}

func GetRelationModelRelationEnum

func GetRelationModelRelationEnum() RelationModelRelationEnum

type SampleDataValue

type SampleDataValue struct {
	Sample *QuerySample `json:"sample,omitempty"`

	// 时序数据。
	DataPoints *[]MetricDataPoints `json:"data_points,omitempty"`
}

查询结果详细。

func (SampleDataValue) String

func (o SampleDataValue) String() string

type SearchKey

type SearchKey struct {

	// 应用名称。
	AppName *string `json:"appName,omitempty"`

	// CCE集群ID。
	ClusterId string `json:"clusterId"`

	// 日志所在虚拟机IP。
	HostIP *string `json:"hostIP,omitempty"`

	// CCE容器集群的命名空间。
	NameSpace *string `json:"nameSpace,omitempty"`

	// 日志文件名称。
	PathFile *string `json:"pathFile,omitempty"`

	// 容器实例名称。
	PodName *string `json:"podName,omitempty"`
}

日志过滤条件集合,不同日志来源所需字段不同。

func (SearchKey) String

func (o SearchKey) String() string

type SeriesApiQueryItemParam

type SeriesApiQueryItemParam struct {

	// 通过该数组传递的参数信息进行时间序列查询。
	Series []QuerySeriesOptionParam `json:"series"`
}

时间序列查询参数详情。

func (SeriesApiQueryItemParam) String

func (o SeriesApiQueryItemParam) String() string

type SeriesQueryItemResult

type SeriesQueryItemResult struct {

	// 命名空间。
	Namespace *string `json:"namespace,omitempty"`

	// 维度列表。
	Dimensions *[]DimensionSeries `json:"dimensions,omitempty"`

	// 时间序列名称。
	MetricName *string `json:"metric_name,omitempty"`

	// 时间序列单位。
	Unit *string `json:"unit,omitempty"`

	// 时间序列哈希值。
	DimensionValueHash *string `json:"dimension_value_hash,omitempty"`
}

维度信息。

func (SeriesQueryItemResult) String

func (o SeriesQueryItemResult) String() string

type ShowActionRuleRequest added in v0.1.13

type ShowActionRuleRequest struct {

	// 告警规则名称
	RuleName string `json:"rule_name"`
}

Request Object

func (ShowActionRuleRequest) String added in v0.1.13

func (o ShowActionRuleRequest) String() string

type ShowActionRuleResponse added in v0.1.13

type ShowActionRuleResponse struct {

	// 规则名称
	RuleName *string `json:"rule_name,omitempty"`

	// 项目ID
	ProjectId *string `json:"project_id,omitempty"`

	// 子账号名称
	UserName *string `json:"user_name,omitempty"`

	// 规则描述
	Desc *string `json:"desc,omitempty"`

	// 规则类型。\"1\":通知,\"2\":用户
	Type *ShowActionRuleResponseType `json:"type,omitempty"`

	// 消息模板
	NotificationTemplate *string `json:"notification_template,omitempty"`

	// 创建时间
	CreateTime *int64 `json:"create_time,omitempty"`

	// 修改时间
	UpdateTime *int64 `json:"update_time,omitempty"`

	// 时区
	TimeZone *string `json:"time_zone,omitempty"`

	// SMN主题信息,不能大于5
	SmnTopics      *[]SmnTopics `json:"smn_topics,omitempty"`
	HttpStatusCode int          `json:"-"`
}

Response Object

func (ShowActionRuleResponse) String added in v0.1.13

func (o ShowActionRuleResponse) String() string

type ShowActionRuleResponseType added in v0.1.19

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

func (ShowActionRuleResponseType) MarshalJSON added in v0.1.19

func (c ShowActionRuleResponseType) MarshalJSON() ([]byte, error)

func (*ShowActionRuleResponseType) UnmarshalJSON added in v0.1.19

func (c *ShowActionRuleResponseType) UnmarshalJSON(b []byte) error

func (ShowActionRuleResponseType) Value added in v0.1.19

type ShowActionRuleResponseTypeEnum added in v0.1.19

type ShowActionRuleResponseTypeEnum struct {
	E_1 ShowActionRuleResponseType
	E_2 ShowActionRuleResponseType
}

func GetShowActionRuleResponseTypeEnum added in v0.1.19

func GetShowActionRuleResponseTypeEnum() ShowActionRuleResponseTypeEnum

type ShowAlarmRuleRequest

type ShowAlarmRuleRequest struct {

	// 阈值规则ID。
	AlarmRuleId string `json:"alarm_rule_id"`
}

Request Object

func (ShowAlarmRuleRequest) String

func (o ShowAlarmRuleRequest) String() string

type ShowAlarmRuleResponse

type ShowAlarmRuleResponse struct {
	MetaData *MetaData `json:"meta_data,omitempty"`

	// 阈值规则列表。
	Thresholds     *[]QueryAlarmResult `json:"thresholds,omitempty"`
	HttpStatusCode int                 `json:"-"`
}

Response Object

func (ShowAlarmRuleResponse) String

func (o ShowAlarmRuleResponse) String() string

type ShowMetricsDataRequest

type ShowMetricsDataRequest struct {

	// 用于对查询到的监控数据进行断点插值,默认值为-1。 -1:断点处使用-1进行表示。 0 :断点处使用0进行表示。 null:断点处使用null进行表示。 average:断点处使用前后邻近的有效数据的平均值进行表示,如果不存在有效数据则使用null进行表示。
	FillValue *ShowMetricsDataRequestFillValue `json:"fillValue,omitempty"`

	Body *QueryMetricDataParam `json:"body,omitempty"`
}

Request Object

func (ShowMetricsDataRequest) String

func (o ShowMetricsDataRequest) String() string

type ShowMetricsDataRequestFillValue

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

func (ShowMetricsDataRequestFillValue) MarshalJSON

func (c ShowMetricsDataRequestFillValue) MarshalJSON() ([]byte, error)

func (*ShowMetricsDataRequestFillValue) UnmarshalJSON

func (c *ShowMetricsDataRequestFillValue) UnmarshalJSON(b []byte) error

func (ShowMetricsDataRequestFillValue) Value added in v0.0.90

type ShowMetricsDataResponse

type ShowMetricsDataResponse struct {

	// 响应码。
	ErrorCode *string `json:"errorCode,omitempty"`

	// 响应信息描述。
	ErrorMessage *string `json:"errorMessage,omitempty"`

	// 指标对象列表。
	Metrics        *[]MetricDataValue `json:"metrics,omitempty"`
	HttpStatusCode int                `json:"-"`
}

Response Object

func (ShowMetricsDataResponse) String

func (o ShowMetricsDataResponse) String() string

type SmnInfo added in v0.1.13

type SmnInfo struct {

	// smn发送消息的内容
	SmnNotifiedContent *string `json:"smn_notified_content,omitempty"`

	// smn的订阅的状态
	SmnSubscriptionStatus *string `json:"smn_subscription_status,omitempty"`

	// smn的订阅类型
	SmnSubscriptionType *string `json:"smn_subscription_type,omitempty"`
}

SMN信息

func (SmnInfo) String added in v0.1.13

func (o SmnInfo) String() string

type SmnResponse added in v0.1.13

type SmnResponse struct {

	// 发送时间。
	SentTime *int64 `json:"sent_time,omitempty"`

	// 发送的通知的消息内容。
	SmnNotifiedHistory *[]SmnInfo `json:"smn_notified_history,omitempty"`

	// 请求smn服务的请求id。
	SmnRequestId *string `json:"smn_request_id,omitempty"`

	// 调用smn服务返回的信息。
	SmnResponseBody *string `json:"smn_response_body,omitempty"`

	// 调用smn服务返回的http状态码。
	SmnResponseCode *string `json:"smn_response_code,omitempty"`

	// smn的主题。
	SmnTopic *string `json:"smn_topic,omitempty"`
}

SMN返回的发送结果信息

func (SmnResponse) String added in v0.1.13

func (o SmnResponse) String() string

type SmnTopics added in v0.1.13

type SmnTopics struct {

	// Topic的显示名,推送邮件消息时,作为邮件发件人显示。显示名的长度为192byte或64个中文。默认值为空。
	DisplayName *string `json:"display_name,omitempty"`

	// 创建topic的名字。Topic名称只能包含大写字母、小写字母、数字、-和_,且必须由大写字母、小写字母或数字开头,长度为1到255个字符。
	Name string `json:"name"`

	// SMN消息推送策略。取值为0或1
	PushPolicy int32 `json:"push_policy"`

	// topic中订阅者的状态。0:主题已删除或主题下订阅列表为空。1:主题下的订阅列表存在状态为“已订阅”的订阅信息。2:主题下的订阅信息状态处于“未订阅”或“已取消”。
	Status *SmnTopicsStatus `json:"status,omitempty"`

	// Topic的唯一的资源标识。
	TopicUrn string `json:"topic_urn"`
}

smn主题相关信息

func (SmnTopics) String added in v0.1.13

func (o SmnTopics) String() string

type SmnTopicsStatus added in v0.1.19

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

func (SmnTopicsStatus) MarshalJSON added in v0.1.19

func (c SmnTopicsStatus) MarshalJSON() ([]byte, error)

func (*SmnTopicsStatus) UnmarshalJSON added in v0.1.19

func (c *SmnTopicsStatus) UnmarshalJSON(b []byte) error

func (SmnTopicsStatus) Value added in v0.1.19

func (c SmnTopicsStatus) Value() int32

type SmnTopicsStatusEnum added in v0.1.19

type SmnTopicsStatusEnum struct {
	E_0 SmnTopicsStatus
	E_1 SmnTopicsStatus
	E_2 SmnTopicsStatus
}

func GetSmnTopicsStatusEnum added in v0.1.19

func GetSmnTopicsStatusEnum() SmnTopicsStatusEnum

type StatisticValue

type StatisticValue struct {

	// 统计方式。
	Statistic *string `json:"statistic,omitempty"`

	// 统计结果。
	Value *float64 `json:"value,omitempty"`
}

统计结果

func (StatisticValue) String

func (o StatisticValue) String() string

type UpdateActionRuleRequest added in v0.1.13

type UpdateActionRuleRequest struct {
	Body *ActionRule `json:"body,omitempty"`
}

Request Object

func (UpdateActionRuleRequest) String added in v0.1.13

func (o UpdateActionRuleRequest) String() string

type UpdateActionRuleResponse added in v0.1.13

type UpdateActionRuleResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (UpdateActionRuleResponse) String added in v0.1.13

func (o UpdateActionRuleResponse) String() string

type UpdateAlarmRuleParam added in v0.0.77

type UpdateAlarmRuleParam struct {

	// 是否启用通知。
	ActionEnabled *bool `json:"action_enabled,omitempty"`

	// 告警状态通知列表。
	AlarmActions *[]string `json:"alarm_actions,omitempty"`

	// 告警清除建议。
	AlarmAdvice *string `json:"alarm_advice,omitempty"`

	// 阈值规则描述。
	AlarmDescription *string `json:"alarm_description,omitempty"`

	// 告警级别。1:紧急,2:重要,3:一般,4:提示。
	AlarmLevel *UpdateAlarmRuleParamAlarmLevel `json:"alarm_level,omitempty"`

	// 阈值规则名称。
	AlarmRuleName string `json:"alarm_rule_name"`

	// 超限条件。
	ComparisonOperator *string `json:"comparison_operator,omitempty"`

	// 时间序列维度。
	Dimensions *[]Dimension `json:"dimensions,omitempty"`

	// 间隔周期。
	EvaluationPeriods *int32 `json:"evaluation_periods,omitempty"`

	// 阈值规则是否启用。
	IdTurnOn *bool `json:"id_turn_on,omitempty"`

	// 数据不足通知列表。
	InsufficientDataActions *[]string `json:"insufficient_data_actions,omitempty"`

	// 时间序列名称。名称长度取值范围为1~255个字符。
	MetricName *string `json:"metric_name,omitempty"`

	// 时间序列命名空间。
	Namespace *string `json:"namespace,omitempty"`

	// 正常状态通知列表。
	OkActions *[]string `json:"ok_actions,omitempty"`

	// 统计周期。
	Period *int32 `json:"period,omitempty"`

	// 统计方式。
	Statistic *UpdateAlarmRuleParamStatistic `json:"statistic,omitempty"`

	// 超限值。
	Threshold *string `json:"threshold,omitempty"`

	// 时间序列单位
	Unit *string `json:"unit,omitempty"`
}

阈值规则实体

func (UpdateAlarmRuleParam) String added in v0.0.77

func (o UpdateAlarmRuleParam) String() string

type UpdateAlarmRuleParamAlarmLevel added in v0.0.77

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

func (UpdateAlarmRuleParamAlarmLevel) MarshalJSON added in v0.0.77

func (c UpdateAlarmRuleParamAlarmLevel) MarshalJSON() ([]byte, error)

func (*UpdateAlarmRuleParamAlarmLevel) UnmarshalJSON added in v0.0.77

func (c *UpdateAlarmRuleParamAlarmLevel) UnmarshalJSON(b []byte) error

func (UpdateAlarmRuleParamAlarmLevel) Value added in v0.0.90

type UpdateAlarmRuleParamAlarmLevelEnum added in v0.0.77

func GetUpdateAlarmRuleParamAlarmLevelEnum added in v0.0.77

func GetUpdateAlarmRuleParamAlarmLevelEnum() UpdateAlarmRuleParamAlarmLevelEnum

type UpdateAlarmRuleParamStatistic added in v0.0.77

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

func (UpdateAlarmRuleParamStatistic) MarshalJSON added in v0.0.77

func (c UpdateAlarmRuleParamStatistic) MarshalJSON() ([]byte, error)

func (*UpdateAlarmRuleParamStatistic) UnmarshalJSON added in v0.0.77

func (c *UpdateAlarmRuleParamStatistic) UnmarshalJSON(b []byte) error

func (UpdateAlarmRuleParamStatistic) Value added in v0.0.90

type UpdateAlarmRuleParamStatisticEnum added in v0.0.77

type UpdateAlarmRuleParamStatisticEnum struct {
	MAXIMUM      UpdateAlarmRuleParamStatistic
	MINIMUM      UpdateAlarmRuleParamStatistic
	AVERAGE      UpdateAlarmRuleParamStatistic
	SUM          UpdateAlarmRuleParamStatistic
	SAMPLE_COUNT UpdateAlarmRuleParamStatistic
}

func GetUpdateAlarmRuleParamStatisticEnum added in v0.0.77

func GetUpdateAlarmRuleParamStatisticEnum() UpdateAlarmRuleParamStatisticEnum

type UpdateAlarmRuleRequest

type UpdateAlarmRuleRequest struct {
	Body *UpdateAlarmRuleParam `json:"body,omitempty"`
}

Request Object

func (UpdateAlarmRuleRequest) String

func (o UpdateAlarmRuleRequest) String() string

type UpdateAlarmRuleResponse

type UpdateAlarmRuleResponse struct {

	// 阈值规则id。
	AlarmRuleId    *int64 `json:"alarm_rule_id,omitempty"`
	HttpStatusCode int    `json:"-"`
}

Response Object

func (UpdateAlarmRuleResponse) String

func (o UpdateAlarmRuleResponse) String() string

type UpdateEventRuleRequest added in v0.1.13

type UpdateEventRuleRequest struct {
	Body *Event2alarmRuleBody `json:"body,omitempty"`
}

Request Object

func (UpdateEventRuleRequest) String added in v0.1.13

func (o UpdateEventRuleRequest) String() string

type UpdateEventRuleResponse added in v0.1.13

type UpdateEventRuleResponse struct {
	Body           *string `json:"body,omitempty"`
	HttpStatusCode int     `json:"-"`
}

Response Object

func (UpdateEventRuleResponse) String added in v0.1.13

func (o UpdateEventRuleResponse) String() string

type UpdateMuteRuleRequest added in v0.1.13

type UpdateMuteRuleRequest struct {
	Body *MuteRule `json:"body,omitempty"`
}

Request Object

func (UpdateMuteRuleRequest) String added in v0.1.13

func (o UpdateMuteRuleRequest) String() string

type UpdateMuteRuleResponse added in v0.1.13

type UpdateMuteRuleResponse struct {
	HttpStatusCode int `json:"-"`
}

Response Object

func (UpdateMuteRuleResponse) String added in v0.1.13

func (o UpdateMuteRuleResponse) String() string

type ValueData

type ValueData struct {

	// 指标名称。长度1~255。
	MetricName string `json:"metric_name"`

	// 数据的类型。 取值范围 只能是\"int\"或\"float\"。
	Type *ValueDataType `json:"type,omitempty"`

	// 数据的单位。长度不超过32个字符。
	Unit *string `json:"unit,omitempty"`

	// 指标数据的值。 取值范围 有效的数值类型。
	Value float64 `json:"value"`
}

指标具体数值。

func (ValueData) String

func (o ValueData) String() string

type ValueDataType

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

func (ValueDataType) MarshalJSON

func (c ValueDataType) MarshalJSON() ([]byte, error)

func (*ValueDataType) UnmarshalJSON

func (c *ValueDataType) UnmarshalJSON(b []byte) error

func (ValueDataType) Value added in v0.0.90

func (c ValueDataType) Value() string

type ValueDataTypeEnum

type ValueDataTypeEnum struct {
	INT   ValueDataType
	FLOAT ValueDataType
}

func GetValueDataTypeEnum

func GetValueDataTypeEnum() ValueDataTypeEnum

Source Files

Jump to

Keyboard shortcuts

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