huaweicloudsdkaom 3.1.85__py2.py3-none-any.whl → 3.1.132__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of huaweicloudsdkaom might be problematic. Click here for more details.
- huaweicloudsdkaom/v1/region/aom_region.py +9 -0
- huaweicloudsdkaom/v2/__init__.py +23 -0
- huaweicloudsdkaom/v2/aom_async_client.py +255 -24
- huaweicloudsdkaom/v2/aom_client.py +255 -24
- huaweicloudsdkaom/v2/model/__init__.py +23 -0
- huaweicloudsdkaom/v2/model/add_or_update_alarm_rule_v4_item_result.py +142 -0
- huaweicloudsdkaom/v2/model/add_or_update_alarm_rule_v4_request_body.py +304 -0
- huaweicloudsdkaom/v2/model/add_or_update_metric_or_event_alarm_rule_request.py +168 -0
- huaweicloudsdkaom/v2/model/add_or_update_metric_or_event_alarm_rule_response.py +174 -0
- huaweicloudsdkaom/v2/model/alarm_notification.py +315 -0
- huaweicloudsdkaom/v2/model/alarm_param_for_v4_db.py +470 -0
- huaweicloudsdkaom/v2/model/alarm_tags.py +173 -0
- huaweicloudsdkaom/v2/model/cmdb_info.py +144 -0
- huaweicloudsdkaom/v2/model/count_events_response.py +32 -3
- huaweicloudsdkaom/v2/model/delete_alarm_rule_v4_request_body.py +114 -0
- huaweicloudsdkaom/v2/model/delete_metric_or_event_alarm_rule_request.py +111 -0
- huaweicloudsdkaom/v2/model/delete_metric_or_event_alarm_rule_response.py +174 -0
- huaweicloudsdkaom/v2/model/delete_prom_instance_request.py +31 -3
- huaweicloudsdkaom/v2/model/event_alarm_spec.py +260 -0
- huaweicloudsdkaom/v2/model/event_trigger_condition.py +260 -0
- huaweicloudsdkaom/v2/model/item_result.py +114 -0
- huaweicloudsdkaom/v2/model/list_agents_request.py +6 -6
- huaweicloudsdkaom/v2/model/list_event_model.py +405 -0
- huaweicloudsdkaom/v2/model/list_events_request.py +88 -1
- huaweicloudsdkaom/v2/model/list_events_response.py +31 -6
- huaweicloudsdkaom/v2/model/list_metric_or_event_alarm_rule_request.py +434 -0
- huaweicloudsdkaom/v2/model/list_metric_or_event_alarm_rule_response.py +174 -0
- huaweicloudsdkaom/v2/model/list_prom_instance_request.py +31 -3
- huaweicloudsdkaom/v2/model/metric_alarm_spec.py +310 -0
- huaweicloudsdkaom/v2/model/no_data_condition.py +173 -0
- huaweicloudsdkaom/v2/model/node_info.py +144 -0
- huaweicloudsdkaom/v2/model/page_info.py +170 -0
- huaweicloudsdkaom/v2/model/push_events_request.py +18 -18
- huaweicloudsdkaom/v2/model/recovery_condition.py +115 -0
- huaweicloudsdkaom/v2/model/smn_info.py +4 -4
- huaweicloudsdkaom/v2/model/trigger_condition.py +742 -0
- huaweicloudsdkaom/v2/region/aom_region.py +9 -0
- huaweicloudsdkaom/v3/aom_async_client.py +19 -19
- huaweicloudsdkaom/v3/aom_client.py +19 -19
- huaweicloudsdkaom/v3/model/biz_app_param.py +12 -12
- huaweicloudsdkaom/v3/model/component_param.py +3 -3
- huaweicloudsdkaom/v3/model/env_param.py +6 -6
- huaweicloudsdkaom/v3/model/sub_app_create_param.py +15 -15
- huaweicloudsdkaom/v3/model/sub_app_update_param.py +9 -9
- huaweicloudsdkaom/v3/region/aom_region.py +9 -0
- huaweicloudsdkaom/v4/__init__.py +21 -0
- huaweicloudsdkaom/v4/aom_async_client.py +279 -0
- huaweicloudsdkaom/v4/aom_client.py +276 -0
- huaweicloudsdkaom/v4/model/__init__.py +18 -0
- huaweicloudsdkaom/v4/model/agent_batch_import_param_new.py +280 -0
- huaweicloudsdkaom/v4/model/agent_import_param_new.py +313 -0
- huaweicloudsdkaom/v4/model/agent_info_param.py +231 -0
- huaweicloudsdkaom/v4/model/agent_info_result.py +463 -0
- huaweicloudsdkaom/v4/model/agent_upgrade_param.py +142 -0
- huaweicloudsdkaom/v4/model/batch_import_agent_request.py +139 -0
- huaweicloudsdkaom/v4/model/batch_import_agent_response.py +116 -0
- huaweicloudsdkaom/v4/model/batch_update_agent_request.py +111 -0
- huaweicloudsdkaom/v4/model/batch_update_agent_response.py +116 -0
- huaweicloudsdkaom/v4/model/plugin_install_basic_param.py +173 -0
- huaweicloudsdkaom/v4/model/show_agent_infos_request.py +111 -0
- huaweicloudsdkaom/v4/model/show_agent_infos_response.py +203 -0
- huaweicloudsdkaom/v4/model/single_agent_param.py +142 -0
- huaweicloudsdkaom/v4/region/__init__.py +0 -0
- huaweicloudsdkaom/v4/region/aom_region.py +100 -0
- {huaweicloudsdkaom-3.1.85.dist-info → huaweicloudsdkaom-3.1.132.dist-info}/METADATA +2 -2
- {huaweicloudsdkaom-3.1.85.dist-info → huaweicloudsdkaom-3.1.132.dist-info}/RECORD +69 -27
- {huaweicloudsdkaom-3.1.85.dist-info → huaweicloudsdkaom-3.1.132.dist-info}/WHEEL +1 -1
- {huaweicloudsdkaom-3.1.85.dist-info → huaweicloudsdkaom-3.1.132.dist-info}/LICENSE +0 -0
- {huaweicloudsdkaom-3.1.85.dist-info → huaweicloudsdkaom-3.1.132.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,405 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
import six
|
|
4
|
+
|
|
5
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class ListEventModel:
|
|
9
|
+
|
|
10
|
+
"""
|
|
11
|
+
Attributes:
|
|
12
|
+
openapi_types (dict): The key is attribute name
|
|
13
|
+
and the value is attribute type.
|
|
14
|
+
attribute_map (dict): The key is attribute name
|
|
15
|
+
and the value is json key in definition.
|
|
16
|
+
"""
|
|
17
|
+
sensitive_list = []
|
|
18
|
+
|
|
19
|
+
openapi_types = {
|
|
20
|
+
'starts_at': 'int',
|
|
21
|
+
'ends_at': 'int',
|
|
22
|
+
'timeout': 'int',
|
|
23
|
+
'metadata': 'dict(str, str)',
|
|
24
|
+
'annotations': 'dict(str, object)',
|
|
25
|
+
'attach_rule': 'dict(str, object)',
|
|
26
|
+
'id': 'str',
|
|
27
|
+
'event_sn': 'str',
|
|
28
|
+
'arrives_at': 'int',
|
|
29
|
+
'enterprise_project_id': 'str',
|
|
30
|
+
'policy': 'dict(str, object)'
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
attribute_map = {
|
|
34
|
+
'starts_at': 'starts_at',
|
|
35
|
+
'ends_at': 'ends_at',
|
|
36
|
+
'timeout': 'timeout',
|
|
37
|
+
'metadata': 'metadata',
|
|
38
|
+
'annotations': 'annotations',
|
|
39
|
+
'attach_rule': 'attach_rule',
|
|
40
|
+
'id': 'id',
|
|
41
|
+
'event_sn': 'event_sn',
|
|
42
|
+
'arrives_at': 'arrives_at',
|
|
43
|
+
'enterprise_project_id': 'enterprise_project_id',
|
|
44
|
+
'policy': 'policy'
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
def __init__(self, starts_at=None, ends_at=None, timeout=None, metadata=None, annotations=None, attach_rule=None, id=None, event_sn=None, arrives_at=None, enterprise_project_id=None, policy=None):
|
|
48
|
+
"""ListEventModel
|
|
49
|
+
|
|
50
|
+
The model defined in huaweicloud sdk
|
|
51
|
+
|
|
52
|
+
:param starts_at: 事件或者告警产生的时间,CST毫秒级时间戳。
|
|
53
|
+
:type starts_at: int
|
|
54
|
+
:param ends_at: 事件或者告警清除的时间,CST毫秒级时间戳,为0时表示未删除。
|
|
55
|
+
:type ends_at: int
|
|
56
|
+
:param timeout: 告警自动清除时间。毫秒数,例如一分钟则填写为60000。默认清除时间为3天,对应数字为 4320 * 1000(即:3天 * 24小时 * 60分钟 * 1000毫秒)。
|
|
57
|
+
:type timeout: int
|
|
58
|
+
:param metadata: 事件或者告警的详细信息,为键值对形式。必须字段为: - event_name:事件或者告警名称,类型为String; - event_severity:事件级别枚举值。类型为String,四种类型 \"Critical\", \"Major\", \"Minor\", \"Info\"; - event_type:事件类别枚举值。类型为String,event为告警事件,alarm为普通告警; - resource_provider:事件对应云服务名称。类型为String; - resource_type:事件对应资源类型。类型为String; - resource_id:事件对应资源信息。类型为String。
|
|
59
|
+
:type metadata: dict(str, str)
|
|
60
|
+
:param annotations: 事件或者告警附加字段,可以为空。
|
|
61
|
+
:type annotations: dict(str, object)
|
|
62
|
+
:param attach_rule: 事件或者告警预留字段,为空。
|
|
63
|
+
:type attach_rule: dict(str, object)
|
|
64
|
+
:param id: 事件或者告警id,系统会自动生成,上报无须填写该字段。
|
|
65
|
+
:type id: str
|
|
66
|
+
:param event_sn: 告警流水号。
|
|
67
|
+
:type event_sn: str
|
|
68
|
+
:param arrives_at: 事件到达系统时间,CST毫秒级时间戳。
|
|
69
|
+
:type arrives_at: int
|
|
70
|
+
:param enterprise_project_id: 事件或告警所属企业项目id。
|
|
71
|
+
:type enterprise_project_id: str
|
|
72
|
+
:param policy: 开放告警策略
|
|
73
|
+
:type policy: dict(str, object)
|
|
74
|
+
"""
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
self._starts_at = None
|
|
79
|
+
self._ends_at = None
|
|
80
|
+
self._timeout = None
|
|
81
|
+
self._metadata = None
|
|
82
|
+
self._annotations = None
|
|
83
|
+
self._attach_rule = None
|
|
84
|
+
self._id = None
|
|
85
|
+
self._event_sn = None
|
|
86
|
+
self._arrives_at = None
|
|
87
|
+
self._enterprise_project_id = None
|
|
88
|
+
self._policy = None
|
|
89
|
+
self.discriminator = None
|
|
90
|
+
|
|
91
|
+
if starts_at is not None:
|
|
92
|
+
self.starts_at = starts_at
|
|
93
|
+
if ends_at is not None:
|
|
94
|
+
self.ends_at = ends_at
|
|
95
|
+
if timeout is not None:
|
|
96
|
+
self.timeout = timeout
|
|
97
|
+
if metadata is not None:
|
|
98
|
+
self.metadata = metadata
|
|
99
|
+
if annotations is not None:
|
|
100
|
+
self.annotations = annotations
|
|
101
|
+
if attach_rule is not None:
|
|
102
|
+
self.attach_rule = attach_rule
|
|
103
|
+
if id is not None:
|
|
104
|
+
self.id = id
|
|
105
|
+
if event_sn is not None:
|
|
106
|
+
self.event_sn = event_sn
|
|
107
|
+
if arrives_at is not None:
|
|
108
|
+
self.arrives_at = arrives_at
|
|
109
|
+
if enterprise_project_id is not None:
|
|
110
|
+
self.enterprise_project_id = enterprise_project_id
|
|
111
|
+
if policy is not None:
|
|
112
|
+
self.policy = policy
|
|
113
|
+
|
|
114
|
+
@property
|
|
115
|
+
def starts_at(self):
|
|
116
|
+
"""Gets the starts_at of this ListEventModel.
|
|
117
|
+
|
|
118
|
+
事件或者告警产生的时间,CST毫秒级时间戳。
|
|
119
|
+
|
|
120
|
+
:return: The starts_at of this ListEventModel.
|
|
121
|
+
:rtype: int
|
|
122
|
+
"""
|
|
123
|
+
return self._starts_at
|
|
124
|
+
|
|
125
|
+
@starts_at.setter
|
|
126
|
+
def starts_at(self, starts_at):
|
|
127
|
+
"""Sets the starts_at of this ListEventModel.
|
|
128
|
+
|
|
129
|
+
事件或者告警产生的时间,CST毫秒级时间戳。
|
|
130
|
+
|
|
131
|
+
:param starts_at: The starts_at of this ListEventModel.
|
|
132
|
+
:type starts_at: int
|
|
133
|
+
"""
|
|
134
|
+
self._starts_at = starts_at
|
|
135
|
+
|
|
136
|
+
@property
|
|
137
|
+
def ends_at(self):
|
|
138
|
+
"""Gets the ends_at of this ListEventModel.
|
|
139
|
+
|
|
140
|
+
事件或者告警清除的时间,CST毫秒级时间戳,为0时表示未删除。
|
|
141
|
+
|
|
142
|
+
:return: The ends_at of this ListEventModel.
|
|
143
|
+
:rtype: int
|
|
144
|
+
"""
|
|
145
|
+
return self._ends_at
|
|
146
|
+
|
|
147
|
+
@ends_at.setter
|
|
148
|
+
def ends_at(self, ends_at):
|
|
149
|
+
"""Sets the ends_at of this ListEventModel.
|
|
150
|
+
|
|
151
|
+
事件或者告警清除的时间,CST毫秒级时间戳,为0时表示未删除。
|
|
152
|
+
|
|
153
|
+
:param ends_at: The ends_at of this ListEventModel.
|
|
154
|
+
:type ends_at: int
|
|
155
|
+
"""
|
|
156
|
+
self._ends_at = ends_at
|
|
157
|
+
|
|
158
|
+
@property
|
|
159
|
+
def timeout(self):
|
|
160
|
+
"""Gets the timeout of this ListEventModel.
|
|
161
|
+
|
|
162
|
+
告警自动清除时间。毫秒数,例如一分钟则填写为60000。默认清除时间为3天,对应数字为 4320 * 1000(即:3天 * 24小时 * 60分钟 * 1000毫秒)。
|
|
163
|
+
|
|
164
|
+
:return: The timeout of this ListEventModel.
|
|
165
|
+
:rtype: int
|
|
166
|
+
"""
|
|
167
|
+
return self._timeout
|
|
168
|
+
|
|
169
|
+
@timeout.setter
|
|
170
|
+
def timeout(self, timeout):
|
|
171
|
+
"""Sets the timeout of this ListEventModel.
|
|
172
|
+
|
|
173
|
+
告警自动清除时间。毫秒数,例如一分钟则填写为60000。默认清除时间为3天,对应数字为 4320 * 1000(即:3天 * 24小时 * 60分钟 * 1000毫秒)。
|
|
174
|
+
|
|
175
|
+
:param timeout: The timeout of this ListEventModel.
|
|
176
|
+
:type timeout: int
|
|
177
|
+
"""
|
|
178
|
+
self._timeout = timeout
|
|
179
|
+
|
|
180
|
+
@property
|
|
181
|
+
def metadata(self):
|
|
182
|
+
"""Gets the metadata of this ListEventModel.
|
|
183
|
+
|
|
184
|
+
事件或者告警的详细信息,为键值对形式。必须字段为: - event_name:事件或者告警名称,类型为String; - event_severity:事件级别枚举值。类型为String,四种类型 \"Critical\", \"Major\", \"Minor\", \"Info\"; - event_type:事件类别枚举值。类型为String,event为告警事件,alarm为普通告警; - resource_provider:事件对应云服务名称。类型为String; - resource_type:事件对应资源类型。类型为String; - resource_id:事件对应资源信息。类型为String。
|
|
185
|
+
|
|
186
|
+
:return: The metadata of this ListEventModel.
|
|
187
|
+
:rtype: dict(str, str)
|
|
188
|
+
"""
|
|
189
|
+
return self._metadata
|
|
190
|
+
|
|
191
|
+
@metadata.setter
|
|
192
|
+
def metadata(self, metadata):
|
|
193
|
+
"""Sets the metadata of this ListEventModel.
|
|
194
|
+
|
|
195
|
+
事件或者告警的详细信息,为键值对形式。必须字段为: - event_name:事件或者告警名称,类型为String; - event_severity:事件级别枚举值。类型为String,四种类型 \"Critical\", \"Major\", \"Minor\", \"Info\"; - event_type:事件类别枚举值。类型为String,event为告警事件,alarm为普通告警; - resource_provider:事件对应云服务名称。类型为String; - resource_type:事件对应资源类型。类型为String; - resource_id:事件对应资源信息。类型为String。
|
|
196
|
+
|
|
197
|
+
:param metadata: The metadata of this ListEventModel.
|
|
198
|
+
:type metadata: dict(str, str)
|
|
199
|
+
"""
|
|
200
|
+
self._metadata = metadata
|
|
201
|
+
|
|
202
|
+
@property
|
|
203
|
+
def annotations(self):
|
|
204
|
+
"""Gets the annotations of this ListEventModel.
|
|
205
|
+
|
|
206
|
+
事件或者告警附加字段,可以为空。
|
|
207
|
+
|
|
208
|
+
:return: The annotations of this ListEventModel.
|
|
209
|
+
:rtype: dict(str, object)
|
|
210
|
+
"""
|
|
211
|
+
return self._annotations
|
|
212
|
+
|
|
213
|
+
@annotations.setter
|
|
214
|
+
def annotations(self, annotations):
|
|
215
|
+
"""Sets the annotations of this ListEventModel.
|
|
216
|
+
|
|
217
|
+
事件或者告警附加字段,可以为空。
|
|
218
|
+
|
|
219
|
+
:param annotations: The annotations of this ListEventModel.
|
|
220
|
+
:type annotations: dict(str, object)
|
|
221
|
+
"""
|
|
222
|
+
self._annotations = annotations
|
|
223
|
+
|
|
224
|
+
@property
|
|
225
|
+
def attach_rule(self):
|
|
226
|
+
"""Gets the attach_rule of this ListEventModel.
|
|
227
|
+
|
|
228
|
+
事件或者告警预留字段,为空。
|
|
229
|
+
|
|
230
|
+
:return: The attach_rule of this ListEventModel.
|
|
231
|
+
:rtype: dict(str, object)
|
|
232
|
+
"""
|
|
233
|
+
return self._attach_rule
|
|
234
|
+
|
|
235
|
+
@attach_rule.setter
|
|
236
|
+
def attach_rule(self, attach_rule):
|
|
237
|
+
"""Sets the attach_rule of this ListEventModel.
|
|
238
|
+
|
|
239
|
+
事件或者告警预留字段,为空。
|
|
240
|
+
|
|
241
|
+
:param attach_rule: The attach_rule of this ListEventModel.
|
|
242
|
+
:type attach_rule: dict(str, object)
|
|
243
|
+
"""
|
|
244
|
+
self._attach_rule = attach_rule
|
|
245
|
+
|
|
246
|
+
@property
|
|
247
|
+
def id(self):
|
|
248
|
+
"""Gets the id of this ListEventModel.
|
|
249
|
+
|
|
250
|
+
事件或者告警id,系统会自动生成,上报无须填写该字段。
|
|
251
|
+
|
|
252
|
+
:return: The id of this ListEventModel.
|
|
253
|
+
:rtype: str
|
|
254
|
+
"""
|
|
255
|
+
return self._id
|
|
256
|
+
|
|
257
|
+
@id.setter
|
|
258
|
+
def id(self, id):
|
|
259
|
+
"""Sets the id of this ListEventModel.
|
|
260
|
+
|
|
261
|
+
事件或者告警id,系统会自动生成,上报无须填写该字段。
|
|
262
|
+
|
|
263
|
+
:param id: The id of this ListEventModel.
|
|
264
|
+
:type id: str
|
|
265
|
+
"""
|
|
266
|
+
self._id = id
|
|
267
|
+
|
|
268
|
+
@property
|
|
269
|
+
def event_sn(self):
|
|
270
|
+
"""Gets the event_sn of this ListEventModel.
|
|
271
|
+
|
|
272
|
+
告警流水号。
|
|
273
|
+
|
|
274
|
+
:return: The event_sn of this ListEventModel.
|
|
275
|
+
:rtype: str
|
|
276
|
+
"""
|
|
277
|
+
return self._event_sn
|
|
278
|
+
|
|
279
|
+
@event_sn.setter
|
|
280
|
+
def event_sn(self, event_sn):
|
|
281
|
+
"""Sets the event_sn of this ListEventModel.
|
|
282
|
+
|
|
283
|
+
告警流水号。
|
|
284
|
+
|
|
285
|
+
:param event_sn: The event_sn of this ListEventModel.
|
|
286
|
+
:type event_sn: str
|
|
287
|
+
"""
|
|
288
|
+
self._event_sn = event_sn
|
|
289
|
+
|
|
290
|
+
@property
|
|
291
|
+
def arrives_at(self):
|
|
292
|
+
"""Gets the arrives_at of this ListEventModel.
|
|
293
|
+
|
|
294
|
+
事件到达系统时间,CST毫秒级时间戳。
|
|
295
|
+
|
|
296
|
+
:return: The arrives_at of this ListEventModel.
|
|
297
|
+
:rtype: int
|
|
298
|
+
"""
|
|
299
|
+
return self._arrives_at
|
|
300
|
+
|
|
301
|
+
@arrives_at.setter
|
|
302
|
+
def arrives_at(self, arrives_at):
|
|
303
|
+
"""Sets the arrives_at of this ListEventModel.
|
|
304
|
+
|
|
305
|
+
事件到达系统时间,CST毫秒级时间戳。
|
|
306
|
+
|
|
307
|
+
:param arrives_at: The arrives_at of this ListEventModel.
|
|
308
|
+
:type arrives_at: int
|
|
309
|
+
"""
|
|
310
|
+
self._arrives_at = arrives_at
|
|
311
|
+
|
|
312
|
+
@property
|
|
313
|
+
def enterprise_project_id(self):
|
|
314
|
+
"""Gets the enterprise_project_id of this ListEventModel.
|
|
315
|
+
|
|
316
|
+
事件或告警所属企业项目id。
|
|
317
|
+
|
|
318
|
+
:return: The enterprise_project_id of this ListEventModel.
|
|
319
|
+
:rtype: str
|
|
320
|
+
"""
|
|
321
|
+
return self._enterprise_project_id
|
|
322
|
+
|
|
323
|
+
@enterprise_project_id.setter
|
|
324
|
+
def enterprise_project_id(self, enterprise_project_id):
|
|
325
|
+
"""Sets the enterprise_project_id of this ListEventModel.
|
|
326
|
+
|
|
327
|
+
事件或告警所属企业项目id。
|
|
328
|
+
|
|
329
|
+
:param enterprise_project_id: The enterprise_project_id of this ListEventModel.
|
|
330
|
+
:type enterprise_project_id: str
|
|
331
|
+
"""
|
|
332
|
+
self._enterprise_project_id = enterprise_project_id
|
|
333
|
+
|
|
334
|
+
@property
|
|
335
|
+
def policy(self):
|
|
336
|
+
"""Gets the policy of this ListEventModel.
|
|
337
|
+
|
|
338
|
+
开放告警策略
|
|
339
|
+
|
|
340
|
+
:return: The policy of this ListEventModel.
|
|
341
|
+
:rtype: dict(str, object)
|
|
342
|
+
"""
|
|
343
|
+
return self._policy
|
|
344
|
+
|
|
345
|
+
@policy.setter
|
|
346
|
+
def policy(self, policy):
|
|
347
|
+
"""Sets the policy of this ListEventModel.
|
|
348
|
+
|
|
349
|
+
开放告警策略
|
|
350
|
+
|
|
351
|
+
:param policy: The policy of this ListEventModel.
|
|
352
|
+
:type policy: dict(str, object)
|
|
353
|
+
"""
|
|
354
|
+
self._policy = policy
|
|
355
|
+
|
|
356
|
+
def to_dict(self):
|
|
357
|
+
"""Returns the model properties as a dict"""
|
|
358
|
+
result = {}
|
|
359
|
+
|
|
360
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
|
361
|
+
value = getattr(self, attr)
|
|
362
|
+
if isinstance(value, list):
|
|
363
|
+
result[attr] = list(map(
|
|
364
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
|
365
|
+
value
|
|
366
|
+
))
|
|
367
|
+
elif hasattr(value, "to_dict"):
|
|
368
|
+
result[attr] = value.to_dict()
|
|
369
|
+
elif isinstance(value, dict):
|
|
370
|
+
result[attr] = dict(map(
|
|
371
|
+
lambda item: (item[0], item[1].to_dict())
|
|
372
|
+
if hasattr(item[1], "to_dict") else item,
|
|
373
|
+
value.items()
|
|
374
|
+
))
|
|
375
|
+
else:
|
|
376
|
+
if attr in self.sensitive_list:
|
|
377
|
+
result[attr] = "****"
|
|
378
|
+
else:
|
|
379
|
+
result[attr] = value
|
|
380
|
+
|
|
381
|
+
return result
|
|
382
|
+
|
|
383
|
+
def to_str(self):
|
|
384
|
+
"""Returns the string representation of the model"""
|
|
385
|
+
import simplejson as json
|
|
386
|
+
if six.PY2:
|
|
387
|
+
import sys
|
|
388
|
+
reload(sys)
|
|
389
|
+
sys.setdefaultencoding("utf-8")
|
|
390
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
|
391
|
+
|
|
392
|
+
def __repr__(self):
|
|
393
|
+
"""For `print`"""
|
|
394
|
+
return self.to_str()
|
|
395
|
+
|
|
396
|
+
def __eq__(self, other):
|
|
397
|
+
"""Returns true if both objects are equal"""
|
|
398
|
+
if not isinstance(other, ListEventModel):
|
|
399
|
+
return False
|
|
400
|
+
|
|
401
|
+
return self.__dict__ == other.__dict__
|
|
402
|
+
|
|
403
|
+
def __ne__(self, other):
|
|
404
|
+
"""Returns true if both objects are not equal"""
|
|
405
|
+
return not self == other
|
|
@@ -18,21 +18,33 @@ class ListEventsRequest:
|
|
|
18
18
|
|
|
19
19
|
openapi_types = {
|
|
20
20
|
'type': 'str',
|
|
21
|
+
'enterprise_project_id': 'str',
|
|
22
|
+
'limit': 'int',
|
|
23
|
+
'marker': 'str',
|
|
21
24
|
'body': 'EventQueryParam2'
|
|
22
25
|
}
|
|
23
26
|
|
|
24
27
|
attribute_map = {
|
|
25
28
|
'type': 'type',
|
|
29
|
+
'enterprise_project_id': 'Enterprise-Project-Id',
|
|
30
|
+
'limit': 'limit',
|
|
31
|
+
'marker': 'marker',
|
|
26
32
|
'body': 'body'
|
|
27
33
|
}
|
|
28
34
|
|
|
29
|
-
def __init__(self, type=None, body=None):
|
|
35
|
+
def __init__(self, type=None, enterprise_project_id=None, limit=None, marker=None, body=None):
|
|
30
36
|
"""ListEventsRequest
|
|
31
37
|
|
|
32
38
|
The model defined in huaweicloud sdk
|
|
33
39
|
|
|
34
40
|
:param type: 查询类型。type=active_alert代表查询活动告警,type=history_alert代表查询历史告警。不传或者传其他值则返回指定查询条件的所有信息。
|
|
35
41
|
:type type: str
|
|
42
|
+
:param enterprise_project_id: 企业项目id。 - 查询单个企业项目下实例,填写企业项目id。 - 查询所有企业项目下实例,填写“all_granted_eps”。
|
|
43
|
+
:type enterprise_project_id: str
|
|
44
|
+
:param limit: 不填默认值为1000
|
|
45
|
+
:type limit: int
|
|
46
|
+
:param marker: 分页标记,初始为0,后续值为返回体中的next_marker
|
|
47
|
+
:type marker: str
|
|
36
48
|
:param body: Body of the ListEventsRequest
|
|
37
49
|
:type body: :class:`huaweicloudsdkaom.v2.EventQueryParam2`
|
|
38
50
|
"""
|
|
@@ -40,11 +52,20 @@ class ListEventsRequest:
|
|
|
40
52
|
|
|
41
53
|
|
|
42
54
|
self._type = None
|
|
55
|
+
self._enterprise_project_id = None
|
|
56
|
+
self._limit = None
|
|
57
|
+
self._marker = None
|
|
43
58
|
self._body = None
|
|
44
59
|
self.discriminator = None
|
|
45
60
|
|
|
46
61
|
if type is not None:
|
|
47
62
|
self.type = type
|
|
63
|
+
if enterprise_project_id is not None:
|
|
64
|
+
self.enterprise_project_id = enterprise_project_id
|
|
65
|
+
if limit is not None:
|
|
66
|
+
self.limit = limit
|
|
67
|
+
if marker is not None:
|
|
68
|
+
self.marker = marker
|
|
48
69
|
if body is not None:
|
|
49
70
|
self.body = body
|
|
50
71
|
|
|
@@ -70,6 +91,72 @@ class ListEventsRequest:
|
|
|
70
91
|
"""
|
|
71
92
|
self._type = type
|
|
72
93
|
|
|
94
|
+
@property
|
|
95
|
+
def enterprise_project_id(self):
|
|
96
|
+
"""Gets the enterprise_project_id of this ListEventsRequest.
|
|
97
|
+
|
|
98
|
+
企业项目id。 - 查询单个企业项目下实例,填写企业项目id。 - 查询所有企业项目下实例,填写“all_granted_eps”。
|
|
99
|
+
|
|
100
|
+
:return: The enterprise_project_id of this ListEventsRequest.
|
|
101
|
+
:rtype: str
|
|
102
|
+
"""
|
|
103
|
+
return self._enterprise_project_id
|
|
104
|
+
|
|
105
|
+
@enterprise_project_id.setter
|
|
106
|
+
def enterprise_project_id(self, enterprise_project_id):
|
|
107
|
+
"""Sets the enterprise_project_id of this ListEventsRequest.
|
|
108
|
+
|
|
109
|
+
企业项目id。 - 查询单个企业项目下实例,填写企业项目id。 - 查询所有企业项目下实例,填写“all_granted_eps”。
|
|
110
|
+
|
|
111
|
+
:param enterprise_project_id: The enterprise_project_id of this ListEventsRequest.
|
|
112
|
+
:type enterprise_project_id: str
|
|
113
|
+
"""
|
|
114
|
+
self._enterprise_project_id = enterprise_project_id
|
|
115
|
+
|
|
116
|
+
@property
|
|
117
|
+
def limit(self):
|
|
118
|
+
"""Gets the limit of this ListEventsRequest.
|
|
119
|
+
|
|
120
|
+
不填默认值为1000
|
|
121
|
+
|
|
122
|
+
:return: The limit of this ListEventsRequest.
|
|
123
|
+
:rtype: int
|
|
124
|
+
"""
|
|
125
|
+
return self._limit
|
|
126
|
+
|
|
127
|
+
@limit.setter
|
|
128
|
+
def limit(self, limit):
|
|
129
|
+
"""Sets the limit of this ListEventsRequest.
|
|
130
|
+
|
|
131
|
+
不填默认值为1000
|
|
132
|
+
|
|
133
|
+
:param limit: The limit of this ListEventsRequest.
|
|
134
|
+
:type limit: int
|
|
135
|
+
"""
|
|
136
|
+
self._limit = limit
|
|
137
|
+
|
|
138
|
+
@property
|
|
139
|
+
def marker(self):
|
|
140
|
+
"""Gets the marker of this ListEventsRequest.
|
|
141
|
+
|
|
142
|
+
分页标记,初始为0,后续值为返回体中的next_marker
|
|
143
|
+
|
|
144
|
+
:return: The marker of this ListEventsRequest.
|
|
145
|
+
:rtype: str
|
|
146
|
+
"""
|
|
147
|
+
return self._marker
|
|
148
|
+
|
|
149
|
+
@marker.setter
|
|
150
|
+
def marker(self, marker):
|
|
151
|
+
"""Sets the marker of this ListEventsRequest.
|
|
152
|
+
|
|
153
|
+
分页标记,初始为0,后续值为返回体中的next_marker
|
|
154
|
+
|
|
155
|
+
:param marker: The marker of this ListEventsRequest.
|
|
156
|
+
:type marker: str
|
|
157
|
+
"""
|
|
158
|
+
self._marker = marker
|
|
159
|
+
|
|
73
160
|
@property
|
|
74
161
|
def body(self):
|
|
75
162
|
"""Gets the body of this ListEventsRequest.
|
|
@@ -18,29 +18,36 @@ class ListEventsResponse(SdkResponse):
|
|
|
18
18
|
sensitive_list = []
|
|
19
19
|
|
|
20
20
|
openapi_types = {
|
|
21
|
-
'events': 'list[
|
|
21
|
+
'events': 'list[ListEventModel]',
|
|
22
|
+
'page_info': 'PageInfo'
|
|
22
23
|
}
|
|
23
24
|
|
|
24
25
|
attribute_map = {
|
|
25
|
-
'events': 'events'
|
|
26
|
+
'events': 'events',
|
|
27
|
+
'page_info': 'page_info'
|
|
26
28
|
}
|
|
27
29
|
|
|
28
|
-
def __init__(self, events=None):
|
|
30
|
+
def __init__(self, events=None, page_info=None):
|
|
29
31
|
"""ListEventsResponse
|
|
30
32
|
|
|
31
33
|
The model defined in huaweicloud sdk
|
|
32
34
|
|
|
33
35
|
:param events: 事件或者告警详情。
|
|
34
|
-
:type events: list[:class:`huaweicloudsdkaom.v2.
|
|
36
|
+
:type events: list[:class:`huaweicloudsdkaom.v2.ListEventModel`]
|
|
37
|
+
:param page_info:
|
|
38
|
+
:type page_info: :class:`huaweicloudsdkaom.v2.PageInfo`
|
|
35
39
|
"""
|
|
36
40
|
|
|
37
41
|
super(ListEventsResponse, self).__init__()
|
|
38
42
|
|
|
39
43
|
self._events = None
|
|
44
|
+
self._page_info = None
|
|
40
45
|
self.discriminator = None
|
|
41
46
|
|
|
42
47
|
if events is not None:
|
|
43
48
|
self.events = events
|
|
49
|
+
if page_info is not None:
|
|
50
|
+
self.page_info = page_info
|
|
44
51
|
|
|
45
52
|
@property
|
|
46
53
|
def events(self):
|
|
@@ -49,7 +56,7 @@ class ListEventsResponse(SdkResponse):
|
|
|
49
56
|
事件或者告警详情。
|
|
50
57
|
|
|
51
58
|
:return: The events of this ListEventsResponse.
|
|
52
|
-
:rtype: list[:class:`huaweicloudsdkaom.v2.
|
|
59
|
+
:rtype: list[:class:`huaweicloudsdkaom.v2.ListEventModel`]
|
|
53
60
|
"""
|
|
54
61
|
return self._events
|
|
55
62
|
|
|
@@ -60,10 +67,28 @@ class ListEventsResponse(SdkResponse):
|
|
|
60
67
|
事件或者告警详情。
|
|
61
68
|
|
|
62
69
|
:param events: The events of this ListEventsResponse.
|
|
63
|
-
:type events: list[:class:`huaweicloudsdkaom.v2.
|
|
70
|
+
:type events: list[:class:`huaweicloudsdkaom.v2.ListEventModel`]
|
|
64
71
|
"""
|
|
65
72
|
self._events = events
|
|
66
73
|
|
|
74
|
+
@property
|
|
75
|
+
def page_info(self):
|
|
76
|
+
"""Gets the page_info of this ListEventsResponse.
|
|
77
|
+
|
|
78
|
+
:return: The page_info of this ListEventsResponse.
|
|
79
|
+
:rtype: :class:`huaweicloudsdkaom.v2.PageInfo`
|
|
80
|
+
"""
|
|
81
|
+
return self._page_info
|
|
82
|
+
|
|
83
|
+
@page_info.setter
|
|
84
|
+
def page_info(self, page_info):
|
|
85
|
+
"""Sets the page_info of this ListEventsResponse.
|
|
86
|
+
|
|
87
|
+
:param page_info: The page_info of this ListEventsResponse.
|
|
88
|
+
:type page_info: :class:`huaweicloudsdkaom.v2.PageInfo`
|
|
89
|
+
"""
|
|
90
|
+
self._page_info = page_info
|
|
91
|
+
|
|
67
92
|
def to_dict(self):
|
|
68
93
|
"""Returns the model properties as a dict"""
|
|
69
94
|
result = {}
|