tencentcloud-sdk-monitor 1.0.340 → 1.0.341
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/VERSION +1 -1
- data/lib/v20180724/client.rb +456 -0
- data/lib/v20180724/models.rb +1039 -9
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 34d322173746830650bde6ee069a89abbe2c4b31
|
4
|
+
data.tar.gz: ae27911444b300a24b5a2756230e8a394ae90eeb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5ed58a5279f91c52845a0f7126e731fc978eb5756c145c2df40485298d4656193216145096ed136bdb1d2ffa2a9eaa50ebf61d3cf6d0e5523f51a6db27fe4f5f
|
7
|
+
data.tar.gz: dad3f878008464bd794a89b15fe2028813451c229b286fb0f19e2913fa0c1b1c41ed2f70353f5d24a662f75882e8dd8baf510220f036d08808cafc10b29a32d8
|
data/lib/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.341
|
data/lib/v20180724/client.rb
CHANGED
@@ -29,6 +29,30 @@ module TencentCloud
|
|
29
29
|
end
|
30
30
|
|
31
31
|
|
32
|
+
# 绑定 Grafana 可视化服务实例
|
33
|
+
|
34
|
+
# @param request: Request instance for BindPrometheusManagedGrafana.
|
35
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::BindPrometheusManagedGrafanaRequest`
|
36
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::BindPrometheusManagedGrafanaResponse`
|
37
|
+
def BindPrometheusManagedGrafana(request)
|
38
|
+
body = send_request('BindPrometheusManagedGrafana', request.serialize)
|
39
|
+
response = JSON.parse(body)
|
40
|
+
if response['Response'].key?('Error') == false
|
41
|
+
model = BindPrometheusManagedGrafanaResponse.new
|
42
|
+
model.deserialize(response['Response'])
|
43
|
+
model
|
44
|
+
else
|
45
|
+
code = response['Response']['Error']['Code']
|
46
|
+
message = response['Response']['Error']['Message']
|
47
|
+
reqid = response['Response']['RequestId']
|
48
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
49
|
+
end
|
50
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
51
|
+
raise e
|
52
|
+
rescue StandardError => e
|
53
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
54
|
+
end
|
55
|
+
|
32
56
|
# 将告警策略绑定到特定对象
|
33
57
|
|
34
58
|
# @param request: Request instance for BindingPolicyObject.
|
@@ -151,6 +175,30 @@ module TencentCloud
|
|
151
175
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
152
176
|
end
|
153
177
|
|
178
|
+
# 创建 exporter 集成
|
179
|
+
|
180
|
+
# @param request: Request instance for CreateExporterIntegration.
|
181
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::CreateExporterIntegrationRequest`
|
182
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::CreateExporterIntegrationResponse`
|
183
|
+
def CreateExporterIntegration(request)
|
184
|
+
body = send_request('CreateExporterIntegration', request.serialize)
|
185
|
+
response = JSON.parse(body)
|
186
|
+
if response['Response'].key?('Error') == false
|
187
|
+
model = CreateExporterIntegrationResponse.new
|
188
|
+
model.deserialize(response['Response'])
|
189
|
+
model
|
190
|
+
else
|
191
|
+
code = response['Response']['Error']['Code']
|
192
|
+
message = response['Response']['Error']['Message']
|
193
|
+
reqid = response['Response']['RequestId']
|
194
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
195
|
+
end
|
196
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
197
|
+
raise e
|
198
|
+
rescue StandardError => e
|
199
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
200
|
+
end
|
201
|
+
|
154
202
|
# 增加策略组
|
155
203
|
|
156
204
|
# @param request: Request instance for CreatePolicyGroup.
|
@@ -175,6 +223,54 @@ module TencentCloud
|
|
175
223
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
176
224
|
end
|
177
225
|
|
226
|
+
# 创建 Prometheus CVM Agent
|
227
|
+
|
228
|
+
# @param request: Request instance for CreatePrometheusAgent.
|
229
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::CreatePrometheusAgentRequest`
|
230
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::CreatePrometheusAgentResponse`
|
231
|
+
def CreatePrometheusAgent(request)
|
232
|
+
body = send_request('CreatePrometheusAgent', request.serialize)
|
233
|
+
response = JSON.parse(body)
|
234
|
+
if response['Response'].key?('Error') == false
|
235
|
+
model = CreatePrometheusAgentResponse.new
|
236
|
+
model.deserialize(response['Response'])
|
237
|
+
model
|
238
|
+
else
|
239
|
+
code = response['Response']['Error']['Code']
|
240
|
+
message = response['Response']['Error']['Message']
|
241
|
+
reqid = response['Response']['RequestId']
|
242
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
243
|
+
end
|
244
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
245
|
+
raise e
|
246
|
+
rescue StandardError => e
|
247
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
248
|
+
end
|
249
|
+
|
250
|
+
# 创建 Prometheus 抓取任务
|
251
|
+
|
252
|
+
# @param request: Request instance for CreatePrometheusScrapeJob.
|
253
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::CreatePrometheusScrapeJobRequest`
|
254
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::CreatePrometheusScrapeJobResponse`
|
255
|
+
def CreatePrometheusScrapeJob(request)
|
256
|
+
body = send_request('CreatePrometheusScrapeJob', request.serialize)
|
257
|
+
response = JSON.parse(body)
|
258
|
+
if response['Response'].key?('Error') == false
|
259
|
+
model = CreatePrometheusScrapeJobResponse.new
|
260
|
+
model.deserialize(response['Response'])
|
261
|
+
model
|
262
|
+
else
|
263
|
+
code = response['Response']['Error']['Code']
|
264
|
+
message = response['Response']['Error']['Message']
|
265
|
+
reqid = response['Response']['RequestId']
|
266
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
267
|
+
end
|
268
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
269
|
+
raise e
|
270
|
+
rescue StandardError => e
|
271
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
272
|
+
end
|
273
|
+
|
178
274
|
# 在腾讯云容器服务下创建 Prometheus 服务发现。
|
179
275
|
# <p>注意:前提条件,已经通过 Prometheus 控制台集成了对应的腾讯云容器服务,具体请参考
|
180
276
|
# <a href="https://cloud.tencent.com/document/product/248/48859" target="_blank">Agent 安装</a>。</p>
|
@@ -273,6 +369,30 @@ module TencentCloud
|
|
273
369
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
274
370
|
end
|
275
371
|
|
372
|
+
# 删除 exporter 集成
|
373
|
+
|
374
|
+
# @param request: Request instance for DeleteExporterIntegration.
|
375
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::DeleteExporterIntegrationRequest`
|
376
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::DeleteExporterIntegrationResponse`
|
377
|
+
def DeleteExporterIntegration(request)
|
378
|
+
body = send_request('DeleteExporterIntegration', request.serialize)
|
379
|
+
response = JSON.parse(body)
|
380
|
+
if response['Response'].key?('Error') == false
|
381
|
+
model = DeleteExporterIntegrationResponse.new
|
382
|
+
model.deserialize(response['Response'])
|
383
|
+
model
|
384
|
+
else
|
385
|
+
code = response['Response']['Error']['Code']
|
386
|
+
message = response['Response']['Error']['Message']
|
387
|
+
reqid = response['Response']['RequestId']
|
388
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
389
|
+
end
|
390
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
391
|
+
raise e
|
392
|
+
rescue StandardError => e
|
393
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
394
|
+
end
|
395
|
+
|
276
396
|
# 删除告警策略组
|
277
397
|
|
278
398
|
# @param request: Request instance for DeletePolicyGroup.
|
@@ -297,6 +417,30 @@ module TencentCloud
|
|
297
417
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
298
418
|
end
|
299
419
|
|
420
|
+
# 删除 Prometheus 抓取任务
|
421
|
+
|
422
|
+
# @param request: Request instance for DeletePrometheusScrapeJobs.
|
423
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::DeletePrometheusScrapeJobsRequest`
|
424
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::DeletePrometheusScrapeJobsResponse`
|
425
|
+
def DeletePrometheusScrapeJobs(request)
|
426
|
+
body = send_request('DeletePrometheusScrapeJobs', request.serialize)
|
427
|
+
response = JSON.parse(body)
|
428
|
+
if response['Response'].key?('Error') == false
|
429
|
+
model = DeletePrometheusScrapeJobsResponse.new
|
430
|
+
model.deserialize(response['Response'])
|
431
|
+
model
|
432
|
+
else
|
433
|
+
code = response['Response']['Error']['Code']
|
434
|
+
message = response['Response']['Error']['Message']
|
435
|
+
reqid = response['Response']['RequestId']
|
436
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
437
|
+
end
|
438
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
439
|
+
raise e
|
440
|
+
rescue StandardError => e
|
441
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
442
|
+
end
|
443
|
+
|
300
444
|
# 删除在腾讯云容器服务下创建的 Prometheus 服务发现。
|
301
445
|
# <p>注意:前提条件,已经通过 Prometheus 控制台集成了对应的腾讯云容器服务,具体请参考
|
302
446
|
# <a href="https://cloud.tencent.com/document/product/248/48859" target="_blank">Agent 安装</a>。</p>
|
@@ -685,6 +829,30 @@ module TencentCloud
|
|
685
829
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
686
830
|
end
|
687
831
|
|
832
|
+
# 查询 exporter 集成列表
|
833
|
+
|
834
|
+
# @param request: Request instance for DescribeExporterIntegrations.
|
835
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::DescribeExporterIntegrationsRequest`
|
836
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::DescribeExporterIntegrationsResponse`
|
837
|
+
def DescribeExporterIntegrations(request)
|
838
|
+
body = send_request('DescribeExporterIntegrations', request.serialize)
|
839
|
+
response = JSON.parse(body)
|
840
|
+
if response['Response'].key?('Error') == false
|
841
|
+
model = DescribeExporterIntegrationsResponse.new
|
842
|
+
model.deserialize(response['Response'])
|
843
|
+
model
|
844
|
+
else
|
845
|
+
code = response['Response']['Error']['Code']
|
846
|
+
message = response['Response']['Error']['Message']
|
847
|
+
reqid = response['Response']['RequestId']
|
848
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
849
|
+
end
|
850
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
851
|
+
raise e
|
852
|
+
rescue StandardError => e
|
853
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
854
|
+
end
|
855
|
+
|
688
856
|
# 云监控支持多种类型的监控,此接口列出支持的所有类型
|
689
857
|
|
690
858
|
# @param request: Request instance for DescribeMonitorTypes.
|
@@ -829,6 +997,30 @@ module TencentCloud
|
|
829
997
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
830
998
|
end
|
831
999
|
|
1000
|
+
# 列出 Prometheus CVM Agent
|
1001
|
+
|
1002
|
+
# @param request: Request instance for DescribePrometheusAgents.
|
1003
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::DescribePrometheusAgentsRequest`
|
1004
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::DescribePrometheusAgentsResponse`
|
1005
|
+
def DescribePrometheusAgents(request)
|
1006
|
+
body = send_request('DescribePrometheusAgents', request.serialize)
|
1007
|
+
response = JSON.parse(body)
|
1008
|
+
if response['Response'].key?('Error') == false
|
1009
|
+
model = DescribePrometheusAgentsResponse.new
|
1010
|
+
model.deserialize(response['Response'])
|
1011
|
+
model
|
1012
|
+
else
|
1013
|
+
code = response['Response']['Error']['Code']
|
1014
|
+
message = response['Response']['Error']['Message']
|
1015
|
+
reqid = response['Response']['RequestId']
|
1016
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1017
|
+
end
|
1018
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1019
|
+
raise e
|
1020
|
+
rescue StandardError => e
|
1021
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1022
|
+
end
|
1023
|
+
|
832
1024
|
# 本接口 (DescribePrometheusInstances) 用于查询一个或多个实例的详细信息。
|
833
1025
|
# <ul>
|
834
1026
|
# <li>可以根据实例ID、实例名称或者实例状态等信息来查询实例的详细信息</li>
|
@@ -857,6 +1049,30 @@ module TencentCloud
|
|
857
1049
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
858
1050
|
end
|
859
1051
|
|
1052
|
+
# 列出 Prometheus 抓取任务
|
1053
|
+
|
1054
|
+
# @param request: Request instance for DescribePrometheusScrapeJobs.
|
1055
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::DescribePrometheusScrapeJobsRequest`
|
1056
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::DescribePrometheusScrapeJobsResponse`
|
1057
|
+
def DescribePrometheusScrapeJobs(request)
|
1058
|
+
body = send_request('DescribePrometheusScrapeJobs', request.serialize)
|
1059
|
+
response = JSON.parse(body)
|
1060
|
+
if response['Response'].key?('Error') == false
|
1061
|
+
model = DescribePrometheusScrapeJobsResponse.new
|
1062
|
+
model.deserialize(response['Response'])
|
1063
|
+
model
|
1064
|
+
else
|
1065
|
+
code = response['Response']['Error']['Code']
|
1066
|
+
message = response['Response']['Error']['Message']
|
1067
|
+
reqid = response['Response']['RequestId']
|
1068
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1069
|
+
end
|
1070
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1071
|
+
raise e
|
1072
|
+
rescue StandardError => e
|
1073
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1074
|
+
end
|
1075
|
+
|
860
1076
|
# 列出在腾讯云容器服务下创建的 Prometheus 服务发现。
|
861
1077
|
# <p>注意:前提条件,已经通过 Prometheus 控制台集成了对应的腾讯云容器服务,具体请参考
|
862
1078
|
# <a href="https://cloud.tencent.com/document/product/248/48859" target="_blank">Agent 安装</a>。</p>
|
@@ -907,6 +1123,30 @@ module TencentCloud
|
|
907
1123
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
908
1124
|
end
|
909
1125
|
|
1126
|
+
# 彻底删除 Prometheus 实例相关数据,给定的实例必须先被 Terminate
|
1127
|
+
|
1128
|
+
# @param request: Request instance for DestroyPrometheusInstance.
|
1129
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::DestroyPrometheusInstanceRequest`
|
1130
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::DestroyPrometheusInstanceResponse`
|
1131
|
+
def DestroyPrometheusInstance(request)
|
1132
|
+
body = send_request('DestroyPrometheusInstance', request.serialize)
|
1133
|
+
response = JSON.parse(body)
|
1134
|
+
if response['Response'].key?('Error') == false
|
1135
|
+
model = DestroyPrometheusInstanceResponse.new
|
1136
|
+
model.deserialize(response['Response'])
|
1137
|
+
model
|
1138
|
+
else
|
1139
|
+
code = response['Response']['Error']['Code']
|
1140
|
+
message = response['Response']['Error']['Message']
|
1141
|
+
reqid = response['Response']['RequestId']
|
1142
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1143
|
+
end
|
1144
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1145
|
+
raise e
|
1146
|
+
rescue StandardError => e
|
1147
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1148
|
+
end
|
1149
|
+
|
910
1150
|
# 获取云产品的监控数据。此接口不适用于拉取容器服务监控数据,如需拉取容器服务监控数据,请使用[根据维度条件查询监控数据](https://cloud.tencent.com/document/product/248/51845)接口。
|
911
1151
|
# 传入产品的命名空间、对象维度描述和监控指标即可获得相应的监控数据。
|
912
1152
|
# 接口调用频率限制为:20次/秒,1200次/分钟。单请求最多可支持批量拉取10个实例的监控数据,单请求的数据点数限制为1440个。
|
@@ -934,6 +1174,30 @@ module TencentCloud
|
|
934
1174
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
935
1175
|
end
|
936
1176
|
|
1177
|
+
# 获取 Prometheus Agent 管理相关的命令行
|
1178
|
+
|
1179
|
+
# @param request: Request instance for GetPrometheusAgentManagementCommand.
|
1180
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::GetPrometheusAgentManagementCommandRequest`
|
1181
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::GetPrometheusAgentManagementCommandResponse`
|
1182
|
+
def GetPrometheusAgentManagementCommand(request)
|
1183
|
+
body = send_request('GetPrometheusAgentManagementCommand', request.serialize)
|
1184
|
+
response = JSON.parse(body)
|
1185
|
+
if response['Response'].key?('Error') == false
|
1186
|
+
model = GetPrometheusAgentManagementCommandResponse.new
|
1187
|
+
model.deserialize(response['Response'])
|
1188
|
+
model
|
1189
|
+
else
|
1190
|
+
code = response['Response']['Error']['Code']
|
1191
|
+
message = response['Response']['Error']['Message']
|
1192
|
+
reqid = response['Response']['RequestId']
|
1193
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1194
|
+
end
|
1195
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1196
|
+
raise e
|
1197
|
+
rescue StandardError => e
|
1198
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1199
|
+
end
|
1200
|
+
|
937
1201
|
# 云监控告警编辑告警通知模板
|
938
1202
|
|
939
1203
|
# @param request: Request instance for ModifyAlarmNotice.
|
@@ -1126,6 +1390,30 @@ module TencentCloud
|
|
1126
1390
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1127
1391
|
end
|
1128
1392
|
|
1393
|
+
# 修改 Prometheus 实例相关属性
|
1394
|
+
|
1395
|
+
# @param request: Request instance for ModifyPrometheusInstanceAttributes.
|
1396
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::ModifyPrometheusInstanceAttributesRequest`
|
1397
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::ModifyPrometheusInstanceAttributesResponse`
|
1398
|
+
def ModifyPrometheusInstanceAttributes(request)
|
1399
|
+
body = send_request('ModifyPrometheusInstanceAttributes', request.serialize)
|
1400
|
+
response = JSON.parse(body)
|
1401
|
+
if response['Response'].key?('Error') == false
|
1402
|
+
model = ModifyPrometheusInstanceAttributesResponse.new
|
1403
|
+
model.deserialize(response['Response'])
|
1404
|
+
model
|
1405
|
+
else
|
1406
|
+
code = response['Response']['Error']['Code']
|
1407
|
+
message = response['Response']['Error']['Message']
|
1408
|
+
reqid = response['Response']['RequestId']
|
1409
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1410
|
+
end
|
1411
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1412
|
+
raise e
|
1413
|
+
rescue StandardError => e
|
1414
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1415
|
+
end
|
1416
|
+
|
1129
1417
|
# 默认接口请求频率限制:50次/秒。
|
1130
1418
|
# 默认单租户指标上限:100个。
|
1131
1419
|
# 单次上报最多 30 个指标/值对,请求返回错误时,请求中所有的指标/值均不会被保存。
|
@@ -1205,6 +1493,30 @@ module TencentCloud
|
|
1205
1493
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1206
1494
|
end
|
1207
1495
|
|
1496
|
+
# 销毁按量 Prometheus 实例
|
1497
|
+
|
1498
|
+
# @param request: Request instance for TerminatePrometheusInstances.
|
1499
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::TerminatePrometheusInstancesRequest`
|
1500
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::TerminatePrometheusInstancesResponse`
|
1501
|
+
def TerminatePrometheusInstances(request)
|
1502
|
+
body = send_request('TerminatePrometheusInstances', request.serialize)
|
1503
|
+
response = JSON.parse(body)
|
1504
|
+
if response['Response'].key?('Error') == false
|
1505
|
+
model = TerminatePrometheusInstancesResponse.new
|
1506
|
+
model.deserialize(response['Response'])
|
1507
|
+
model
|
1508
|
+
else
|
1509
|
+
code = response['Response']['Error']['Code']
|
1510
|
+
message = response['Response']['Error']['Message']
|
1511
|
+
reqid = response['Response']['RequestId']
|
1512
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1513
|
+
end
|
1514
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1515
|
+
raise e
|
1516
|
+
rescue StandardError => e
|
1517
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1518
|
+
end
|
1519
|
+
|
1208
1520
|
# 删除全部的关联对象
|
1209
1521
|
|
1210
1522
|
# @param request: Request instance for UnBindingAllPolicyObject.
|
@@ -1253,6 +1565,54 @@ module TencentCloud
|
|
1253
1565
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1254
1566
|
end
|
1255
1567
|
|
1568
|
+
# 解除实例绑定的 Grafana 可视化实例
|
1569
|
+
|
1570
|
+
# @param request: Request instance for UnbindPrometheusManagedGrafana.
|
1571
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::UnbindPrometheusManagedGrafanaRequest`
|
1572
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::UnbindPrometheusManagedGrafanaResponse`
|
1573
|
+
def UnbindPrometheusManagedGrafana(request)
|
1574
|
+
body = send_request('UnbindPrometheusManagedGrafana', request.serialize)
|
1575
|
+
response = JSON.parse(body)
|
1576
|
+
if response['Response'].key?('Error') == false
|
1577
|
+
model = UnbindPrometheusManagedGrafanaResponse.new
|
1578
|
+
model.deserialize(response['Response'])
|
1579
|
+
model
|
1580
|
+
else
|
1581
|
+
code = response['Response']['Error']['Code']
|
1582
|
+
message = response['Response']['Error']['Message']
|
1583
|
+
reqid = response['Response']['RequestId']
|
1584
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1585
|
+
end
|
1586
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1587
|
+
raise e
|
1588
|
+
rescue StandardError => e
|
1589
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1590
|
+
end
|
1591
|
+
|
1592
|
+
# 删除 Grafana Dashboard
|
1593
|
+
|
1594
|
+
# @param request: Request instance for UninstallGrafanaDashboard.
|
1595
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::UninstallGrafanaDashboardRequest`
|
1596
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::UninstallGrafanaDashboardResponse`
|
1597
|
+
def UninstallGrafanaDashboard(request)
|
1598
|
+
body = send_request('UninstallGrafanaDashboard', request.serialize)
|
1599
|
+
response = JSON.parse(body)
|
1600
|
+
if response['Response'].key?('Error') == false
|
1601
|
+
model = UninstallGrafanaDashboardResponse.new
|
1602
|
+
model.deserialize(response['Response'])
|
1603
|
+
model
|
1604
|
+
else
|
1605
|
+
code = response['Response']['Error']['Code']
|
1606
|
+
message = response['Response']['Error']['Message']
|
1607
|
+
reqid = response['Response']['RequestId']
|
1608
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1609
|
+
end
|
1610
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1611
|
+
raise e
|
1612
|
+
rescue StandardError => e
|
1613
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1614
|
+
end
|
1615
|
+
|
1256
1616
|
# 更新 Prometheus 的报警规则。
|
1257
1617
|
|
1258
1618
|
# 请注意,**告警对象和告警消息是 Prometheus Rule Annotations 的特殊字段,需要通过 annotations 来传递,对应的 Key 分别为summary/description**,,请参考 [Prometheus Rule更多配置请参考](https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/)。
|
@@ -1303,6 +1663,78 @@ module TencentCloud
|
|
1303
1663
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1304
1664
|
end
|
1305
1665
|
|
1666
|
+
# 更新 exporter 集成配置
|
1667
|
+
|
1668
|
+
# @param request: Request instance for UpdateExporterIntegration.
|
1669
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::UpdateExporterIntegrationRequest`
|
1670
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::UpdateExporterIntegrationResponse`
|
1671
|
+
def UpdateExporterIntegration(request)
|
1672
|
+
body = send_request('UpdateExporterIntegration', request.serialize)
|
1673
|
+
response = JSON.parse(body)
|
1674
|
+
if response['Response'].key?('Error') == false
|
1675
|
+
model = UpdateExporterIntegrationResponse.new
|
1676
|
+
model.deserialize(response['Response'])
|
1677
|
+
model
|
1678
|
+
else
|
1679
|
+
code = response['Response']['Error']['Code']
|
1680
|
+
message = response['Response']['Error']['Message']
|
1681
|
+
reqid = response['Response']['RequestId']
|
1682
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1683
|
+
end
|
1684
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1685
|
+
raise e
|
1686
|
+
rescue StandardError => e
|
1687
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1688
|
+
end
|
1689
|
+
|
1690
|
+
# 更新 Prometheus CVM Agent 状态
|
1691
|
+
|
1692
|
+
# @param request: Request instance for UpdatePrometheusAgentStatus.
|
1693
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::UpdatePrometheusAgentStatusRequest`
|
1694
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::UpdatePrometheusAgentStatusResponse`
|
1695
|
+
def UpdatePrometheusAgentStatus(request)
|
1696
|
+
body = send_request('UpdatePrometheusAgentStatus', request.serialize)
|
1697
|
+
response = JSON.parse(body)
|
1698
|
+
if response['Response'].key?('Error') == false
|
1699
|
+
model = UpdatePrometheusAgentStatusResponse.new
|
1700
|
+
model.deserialize(response['Response'])
|
1701
|
+
model
|
1702
|
+
else
|
1703
|
+
code = response['Response']['Error']['Code']
|
1704
|
+
message = response['Response']['Error']['Message']
|
1705
|
+
reqid = response['Response']['RequestId']
|
1706
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1707
|
+
end
|
1708
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1709
|
+
raise e
|
1710
|
+
rescue StandardError => e
|
1711
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1712
|
+
end
|
1713
|
+
|
1714
|
+
# 更新 Prometheus 抓取任务
|
1715
|
+
|
1716
|
+
# @param request: Request instance for UpdatePrometheusScrapeJob.
|
1717
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::UpdatePrometheusScrapeJobRequest`
|
1718
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::UpdatePrometheusScrapeJobResponse`
|
1719
|
+
def UpdatePrometheusScrapeJob(request)
|
1720
|
+
body = send_request('UpdatePrometheusScrapeJob', request.serialize)
|
1721
|
+
response = JSON.parse(body)
|
1722
|
+
if response['Response'].key?('Error') == false
|
1723
|
+
model = UpdatePrometheusScrapeJobResponse.new
|
1724
|
+
model.deserialize(response['Response'])
|
1725
|
+
model
|
1726
|
+
else
|
1727
|
+
code = response['Response']['Error']['Code']
|
1728
|
+
message = response['Response']['Error']['Message']
|
1729
|
+
reqid = response['Response']['RequestId']
|
1730
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1731
|
+
end
|
1732
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1733
|
+
raise e
|
1734
|
+
rescue StandardError => e
|
1735
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1736
|
+
end
|
1737
|
+
|
1306
1738
|
# 在腾讯云容器服务下更新 Prometheus 服务发现。
|
1307
1739
|
# <p>注意:前提条件,已经通过 Prometheus 控制台集成了对应的腾讯云容器服务,具体请参考
|
1308
1740
|
# <a href="https://cloud.tencent.com/document/product/248/48859" target="_blank">Agent 安装</a>。</p>
|
@@ -1329,6 +1761,30 @@ module TencentCloud
|
|
1329
1761
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1330
1762
|
end
|
1331
1763
|
|
1764
|
+
# 升级 Grafana Dashboard
|
1765
|
+
|
1766
|
+
# @param request: Request instance for UpgradeGrafanaDashboard.
|
1767
|
+
# @type request: :class:`Tencentcloud::monitor::V20180724::UpgradeGrafanaDashboardRequest`
|
1768
|
+
# @rtype: :class:`Tencentcloud::monitor::V20180724::UpgradeGrafanaDashboardResponse`
|
1769
|
+
def UpgradeGrafanaDashboard(request)
|
1770
|
+
body = send_request('UpgradeGrafanaDashboard', request.serialize)
|
1771
|
+
response = JSON.parse(body)
|
1772
|
+
if response['Response'].key?('Error') == false
|
1773
|
+
model = UpgradeGrafanaDashboardResponse.new
|
1774
|
+
model.deserialize(response['Response'])
|
1775
|
+
model
|
1776
|
+
else
|
1777
|
+
code = response['Response']['Error']['Code']
|
1778
|
+
message = response['Response']['Error']['Message']
|
1779
|
+
reqid = response['Response']['RequestId']
|
1780
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1781
|
+
end
|
1782
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1783
|
+
raise e
|
1784
|
+
rescue StandardError => e
|
1785
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1786
|
+
end
|
1787
|
+
|
1332
1788
|
|
1333
1789
|
end
|
1334
1790
|
end
|