tencentcloud-sdk-ecm 1.0.200
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/lib/VERSION +1 -0
- data/lib/tencentcloud-sdk-ecm.rb +11 -0
- data/lib/v20190719/client.rb +3183 -0
- data/lib/v20190719/models.rb +10776 -0
- metadata +66 -0
@@ -0,0 +1,3183 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. All Rights Reserved.
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
require 'json'
|
18
|
+
|
19
|
+
module TencentCloud
|
20
|
+
module Ecm
|
21
|
+
module V20190719
|
22
|
+
class Client < TencentCloud::Common::AbstractClient
|
23
|
+
|
24
|
+
def initialize(credential, region, profile = nil)
|
25
|
+
api_version = '2019-07-19'
|
26
|
+
api_endpoint = 'ecm.tencentcloudapi.com'
|
27
|
+
sdk_version = 'ECM_' + File.read(File.expand_path('../VERSION', __dir__)).strip
|
28
|
+
super(credential, region, api_version, api_endpoint, sdk_version, profile)
|
29
|
+
end
|
30
|
+
|
31
|
+
|
32
|
+
# 申请一个或多个弹性公网IP(简称 EIP)
|
33
|
+
|
34
|
+
# @param request: Request instance for AllocateAddresses.
|
35
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::AllocateAddressesRequest`
|
36
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::AllocateAddressesResponse`
|
37
|
+
def AllocateAddresses(request)
|
38
|
+
body = send_request('AllocateAddresses', request.serialize)
|
39
|
+
response = JSON.parse(body)
|
40
|
+
if response['Response'].key?('Error') == false
|
41
|
+
model = AllocateAddressesResponse.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
|
+
|
56
|
+
# 本接口(AssignIpv6Addresses)用于弹性网卡申请IPv6地址。
|
57
|
+
|
58
|
+
# @param request: Request instance for AssignIpv6Addresses.
|
59
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::AssignIpv6AddressesRequest`
|
60
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::AssignIpv6AddressesResponse`
|
61
|
+
def AssignIpv6Addresses(request)
|
62
|
+
body = send_request('AssignIpv6Addresses', request.serialize)
|
63
|
+
response = JSON.parse(body)
|
64
|
+
if response['Response'].key?('Error') == false
|
65
|
+
model = AssignIpv6AddressesResponse.new
|
66
|
+
model.deserialize(response['Response'])
|
67
|
+
model
|
68
|
+
else
|
69
|
+
code = response['Response']['Error']['Code']
|
70
|
+
message = response['Response']['Error']['Message']
|
71
|
+
reqid = response['Response']['RequestId']
|
72
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
73
|
+
end
|
74
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
75
|
+
raise e
|
76
|
+
rescue StandardError => e
|
77
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
78
|
+
end
|
79
|
+
|
80
|
+
# 弹性网卡申请内网 IP
|
81
|
+
|
82
|
+
# @param request: Request instance for AssignPrivateIpAddresses.
|
83
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::AssignPrivateIpAddressesRequest`
|
84
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::AssignPrivateIpAddressesResponse`
|
85
|
+
def AssignPrivateIpAddresses(request)
|
86
|
+
body = send_request('AssignPrivateIpAddresses', request.serialize)
|
87
|
+
response = JSON.parse(body)
|
88
|
+
if response['Response'].key?('Error') == false
|
89
|
+
model = AssignPrivateIpAddressesResponse.new
|
90
|
+
model.deserialize(response['Response'])
|
91
|
+
model
|
92
|
+
else
|
93
|
+
code = response['Response']['Error']['Code']
|
94
|
+
message = response['Response']['Error']['Message']
|
95
|
+
reqid = response['Response']['RequestId']
|
96
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
97
|
+
end
|
98
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
99
|
+
raise e
|
100
|
+
rescue StandardError => e
|
101
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
102
|
+
end
|
103
|
+
|
104
|
+
# 将弹性公网IP(简称 EIP)绑定到实例或弹性网卡的指定内网 IP 上。
|
105
|
+
# 将 EIP 绑定到实例(ECM)上,其本质是将 EIP 绑定到实例上主网卡的主内网 IP 上。
|
106
|
+
# 将 EIP 绑定到指定网卡的内网 IP上,内网IP已经绑定了EIP或普通公网IP,则反馈失败。必须先解绑该 EIP,才能再绑定新的。
|
107
|
+
# 只有状态为 UNBIND 的 EIP 才能够绑定内网IP。
|
108
|
+
|
109
|
+
# @param request: Request instance for AssociateAddress.
|
110
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::AssociateAddressRequest`
|
111
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::AssociateAddressResponse`
|
112
|
+
def AssociateAddress(request)
|
113
|
+
body = send_request('AssociateAddress', request.serialize)
|
114
|
+
response = JSON.parse(body)
|
115
|
+
if response['Response'].key?('Error') == false
|
116
|
+
model = AssociateAddressResponse.new
|
117
|
+
model.deserialize(response['Response'])
|
118
|
+
model
|
119
|
+
else
|
120
|
+
code = response['Response']['Error']['Code']
|
121
|
+
message = response['Response']['Error']['Message']
|
122
|
+
reqid = response['Response']['RequestId']
|
123
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
124
|
+
end
|
125
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
126
|
+
raise e
|
127
|
+
rescue StandardError => e
|
128
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
129
|
+
end
|
130
|
+
|
131
|
+
# 绑定安全组
|
132
|
+
|
133
|
+
# @param request: Request instance for AssociateSecurityGroups.
|
134
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::AssociateSecurityGroupsRequest`
|
135
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::AssociateSecurityGroupsResponse`
|
136
|
+
def AssociateSecurityGroups(request)
|
137
|
+
body = send_request('AssociateSecurityGroups', request.serialize)
|
138
|
+
response = JSON.parse(body)
|
139
|
+
if response['Response'].key?('Error') == false
|
140
|
+
model = AssociateSecurityGroupsResponse.new
|
141
|
+
model.deserialize(response['Response'])
|
142
|
+
model
|
143
|
+
else
|
144
|
+
code = response['Response']['Error']['Code']
|
145
|
+
message = response['Response']['Error']['Message']
|
146
|
+
reqid = response['Response']['RequestId']
|
147
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
148
|
+
end
|
149
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
150
|
+
raise e
|
151
|
+
rescue StandardError => e
|
152
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
153
|
+
end
|
154
|
+
|
155
|
+
# 本接口(AttachDisks)用于挂载云硬盘。
|
156
|
+
|
157
|
+
# * 支持批量操作,将多块云盘挂载到同一云主机。如果多个云盘中存在不允许挂载的云盘,则操作不执行,返回特定的错误码。
|
158
|
+
# * 本接口为异步接口,当挂载云盘的请求成功返回时,表示后台已发起挂载云盘的操作,可通过接口[DescribeDisks](/document/product/362/16315)来查询对应云盘的状态,如果云盘的状态由“ATTACHING”变为“ATTACHED”,则为挂载成功。
|
159
|
+
|
160
|
+
# @param request: Request instance for AttachDisks.
|
161
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::AttachDisksRequest`
|
162
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::AttachDisksResponse`
|
163
|
+
def AttachDisks(request)
|
164
|
+
body = send_request('AttachDisks', request.serialize)
|
165
|
+
response = JSON.parse(body)
|
166
|
+
if response['Response'].key?('Error') == false
|
167
|
+
model = AttachDisksResponse.new
|
168
|
+
model.deserialize(response['Response'])
|
169
|
+
model
|
170
|
+
else
|
171
|
+
code = response['Response']['Error']['Code']
|
172
|
+
message = response['Response']['Error']['Message']
|
173
|
+
reqid = response['Response']['RequestId']
|
174
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
175
|
+
end
|
176
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
177
|
+
raise e
|
178
|
+
rescue StandardError => e
|
179
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
180
|
+
end
|
181
|
+
|
182
|
+
# 弹性网卡绑定云主机
|
183
|
+
|
184
|
+
# @param request: Request instance for AttachNetworkInterface.
|
185
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::AttachNetworkInterfaceRequest`
|
186
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::AttachNetworkInterfaceResponse`
|
187
|
+
def AttachNetworkInterface(request)
|
188
|
+
body = send_request('AttachNetworkInterface', request.serialize)
|
189
|
+
response = JSON.parse(body)
|
190
|
+
if response['Response'].key?('Error') == false
|
191
|
+
model = AttachNetworkInterfaceResponse.new
|
192
|
+
model.deserialize(response['Response'])
|
193
|
+
model
|
194
|
+
else
|
195
|
+
code = response['Response']['Error']['Code']
|
196
|
+
message = response['Response']['Error']['Message']
|
197
|
+
reqid = response['Response']['RequestId']
|
198
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
199
|
+
end
|
200
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
201
|
+
raise e
|
202
|
+
rescue StandardError => e
|
203
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
204
|
+
end
|
205
|
+
|
206
|
+
# 批量解绑后端服务。
|
207
|
+
|
208
|
+
# @param request: Request instance for BatchDeregisterTargets.
|
209
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::BatchDeregisterTargetsRequest`
|
210
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::BatchDeregisterTargetsResponse`
|
211
|
+
def BatchDeregisterTargets(request)
|
212
|
+
body = send_request('BatchDeregisterTargets', request.serialize)
|
213
|
+
response = JSON.parse(body)
|
214
|
+
if response['Response'].key?('Error') == false
|
215
|
+
model = BatchDeregisterTargetsResponse.new
|
216
|
+
model.deserialize(response['Response'])
|
217
|
+
model
|
218
|
+
else
|
219
|
+
code = response['Response']['Error']['Code']
|
220
|
+
message = response['Response']['Error']['Message']
|
221
|
+
reqid = response['Response']['RequestId']
|
222
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
223
|
+
end
|
224
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
225
|
+
raise e
|
226
|
+
rescue StandardError => e
|
227
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
228
|
+
end
|
229
|
+
|
230
|
+
# 批量修改监听器绑定的后端机器的转发权重。
|
231
|
+
|
232
|
+
# @param request: Request instance for BatchModifyTargetWeight.
|
233
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::BatchModifyTargetWeightRequest`
|
234
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::BatchModifyTargetWeightResponse`
|
235
|
+
def BatchModifyTargetWeight(request)
|
236
|
+
body = send_request('BatchModifyTargetWeight', request.serialize)
|
237
|
+
response = JSON.parse(body)
|
238
|
+
if response['Response'].key?('Error') == false
|
239
|
+
model = BatchModifyTargetWeightResponse.new
|
240
|
+
model.deserialize(response['Response'])
|
241
|
+
model
|
242
|
+
else
|
243
|
+
code = response['Response']['Error']['Code']
|
244
|
+
message = response['Response']['Error']['Message']
|
245
|
+
reqid = response['Response']['RequestId']
|
246
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
247
|
+
end
|
248
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
249
|
+
raise e
|
250
|
+
rescue StandardError => e
|
251
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
252
|
+
end
|
253
|
+
|
254
|
+
# 批量绑定后端目标。
|
255
|
+
|
256
|
+
# @param request: Request instance for BatchRegisterTargets.
|
257
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::BatchRegisterTargetsRequest`
|
258
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::BatchRegisterTargetsResponse`
|
259
|
+
def BatchRegisterTargets(request)
|
260
|
+
body = send_request('BatchRegisterTargets', request.serialize)
|
261
|
+
response = JSON.parse(body)
|
262
|
+
if response['Response'].key?('Error') == false
|
263
|
+
model = BatchRegisterTargetsResponse.new
|
264
|
+
model.deserialize(response['Response'])
|
265
|
+
model
|
266
|
+
else
|
267
|
+
code = response['Response']['Error']['Code']
|
268
|
+
message = response['Response']['Error']['Message']
|
269
|
+
reqid = response['Response']['RequestId']
|
270
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
271
|
+
end
|
272
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
273
|
+
raise e
|
274
|
+
rescue StandardError => e
|
275
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
276
|
+
end
|
277
|
+
|
278
|
+
# 本接口(CreateDisks)用于创建云硬盘。
|
279
|
+
|
280
|
+
# * 预付费云盘的购买会预先扣除本次云盘购买所需金额,在调用本接口前请确保账户余额充足。
|
281
|
+
# * 本接口支持传入数据盘快照来创建云盘,实现将快照数据复制到新购云盘上。
|
282
|
+
# * 本接口为异步接口,当创建请求下发成功后会返回一个新建的云盘ID列表,此时云盘的创建并未立即完成。可以通过调用[DescribeDisks](/document/product/362/16315)接口根据DiskId查询对应云盘,如果能查到云盘,且状态为'UNATTACHED'或'ATTACHED',则表示创建成功。
|
283
|
+
|
284
|
+
# @param request: Request instance for CreateDisks.
|
285
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateDisksRequest`
|
286
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateDisksResponse`
|
287
|
+
def CreateDisks(request)
|
288
|
+
body = send_request('CreateDisks', request.serialize)
|
289
|
+
response = JSON.parse(body)
|
290
|
+
if response['Response'].key?('Error') == false
|
291
|
+
model = CreateDisksResponse.new
|
292
|
+
model.deserialize(response['Response'])
|
293
|
+
model
|
294
|
+
else
|
295
|
+
code = response['Response']['Error']['Code']
|
296
|
+
message = response['Response']['Error']['Message']
|
297
|
+
reqid = response['Response']['RequestId']
|
298
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
299
|
+
end
|
300
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
301
|
+
raise e
|
302
|
+
rescue StandardError => e
|
303
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
304
|
+
end
|
305
|
+
|
306
|
+
# 本接口(CreateHaVip)用于创建高可用虚拟IP(HAVIP)
|
307
|
+
|
308
|
+
# @param request: Request instance for CreateHaVip.
|
309
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateHaVipRequest`
|
310
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateHaVipResponse`
|
311
|
+
def CreateHaVip(request)
|
312
|
+
body = send_request('CreateHaVip', request.serialize)
|
313
|
+
response = JSON.parse(body)
|
314
|
+
if response['Response'].key?('Error') == false
|
315
|
+
model = CreateHaVipResponse.new
|
316
|
+
model.deserialize(response['Response'])
|
317
|
+
model
|
318
|
+
else
|
319
|
+
code = response['Response']['Error']['Code']
|
320
|
+
message = response['Response']['Error']['Message']
|
321
|
+
reqid = response['Response']['RequestId']
|
322
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
323
|
+
end
|
324
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
325
|
+
raise e
|
326
|
+
rescue StandardError => e
|
327
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
328
|
+
end
|
329
|
+
|
330
|
+
# 本接口(CreateImage)用于将实例的系统盘制作为新镜像,创建后的镜像可以用于创建实例。
|
331
|
+
|
332
|
+
# @param request: Request instance for CreateImage.
|
333
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateImageRequest`
|
334
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateImageResponse`
|
335
|
+
def CreateImage(request)
|
336
|
+
body = send_request('CreateImage', request.serialize)
|
337
|
+
response = JSON.parse(body)
|
338
|
+
if response['Response'].key?('Error') == false
|
339
|
+
model = CreateImageResponse.new
|
340
|
+
model.deserialize(response['Response'])
|
341
|
+
model
|
342
|
+
else
|
343
|
+
code = response['Response']['Error']['Code']
|
344
|
+
message = response['Response']['Error']['Message']
|
345
|
+
reqid = response['Response']['RequestId']
|
346
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
347
|
+
end
|
348
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
349
|
+
raise e
|
350
|
+
rescue StandardError => e
|
351
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
352
|
+
end
|
353
|
+
|
354
|
+
# 用于创建一个 OpenSSH RSA 密钥对,可以用于登录 Linux 实例。
|
355
|
+
|
356
|
+
# @param request: Request instance for CreateKeyPair.
|
357
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateKeyPairRequest`
|
358
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateKeyPairResponse`
|
359
|
+
def CreateKeyPair(request)
|
360
|
+
body = send_request('CreateKeyPair', request.serialize)
|
361
|
+
response = JSON.parse(body)
|
362
|
+
if response['Response'].key?('Error') == false
|
363
|
+
model = CreateKeyPairResponse.new
|
364
|
+
model.deserialize(response['Response'])
|
365
|
+
model
|
366
|
+
else
|
367
|
+
code = response['Response']['Error']['Code']
|
368
|
+
message = response['Response']['Error']['Message']
|
369
|
+
reqid = response['Response']['RequestId']
|
370
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
371
|
+
end
|
372
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
373
|
+
raise e
|
374
|
+
rescue StandardError => e
|
375
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
376
|
+
end
|
377
|
+
|
378
|
+
# 创建负载均衡监听器。
|
379
|
+
|
380
|
+
# @param request: Request instance for CreateListener.
|
381
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateListenerRequest`
|
382
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateListenerResponse`
|
383
|
+
def CreateListener(request)
|
384
|
+
body = send_request('CreateListener', request.serialize)
|
385
|
+
response = JSON.parse(body)
|
386
|
+
if response['Response'].key?('Error') == false
|
387
|
+
model = CreateListenerResponse.new
|
388
|
+
model.deserialize(response['Response'])
|
389
|
+
model
|
390
|
+
else
|
391
|
+
code = response['Response']['Error']['Code']
|
392
|
+
message = response['Response']['Error']['Message']
|
393
|
+
reqid = response['Response']['RequestId']
|
394
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
395
|
+
end
|
396
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
397
|
+
raise e
|
398
|
+
rescue StandardError => e
|
399
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
400
|
+
end
|
401
|
+
|
402
|
+
# 购买负载均衡实例。
|
403
|
+
|
404
|
+
# @param request: Request instance for CreateLoadBalancer.
|
405
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateLoadBalancerRequest`
|
406
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateLoadBalancerResponse`
|
407
|
+
def CreateLoadBalancer(request)
|
408
|
+
body = send_request('CreateLoadBalancer', request.serialize)
|
409
|
+
response = JSON.parse(body)
|
410
|
+
if response['Response'].key?('Error') == false
|
411
|
+
model = CreateLoadBalancerResponse.new
|
412
|
+
model.deserialize(response['Response'])
|
413
|
+
model
|
414
|
+
else
|
415
|
+
code = response['Response']['Error']['Code']
|
416
|
+
message = response['Response']['Error']['Message']
|
417
|
+
reqid = response['Response']['RequestId']
|
418
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
419
|
+
end
|
420
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
421
|
+
raise e
|
422
|
+
rescue StandardError => e
|
423
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
424
|
+
end
|
425
|
+
|
426
|
+
# 创建模块
|
427
|
+
|
428
|
+
# @param request: Request instance for CreateModule.
|
429
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateModuleRequest`
|
430
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateModuleResponse`
|
431
|
+
def CreateModule(request)
|
432
|
+
body = send_request('CreateModule', request.serialize)
|
433
|
+
response = JSON.parse(body)
|
434
|
+
if response['Response'].key?('Error') == false
|
435
|
+
model = CreateModuleResponse.new
|
436
|
+
model.deserialize(response['Response'])
|
437
|
+
model
|
438
|
+
else
|
439
|
+
code = response['Response']['Error']['Code']
|
440
|
+
message = response['Response']['Error']['Message']
|
441
|
+
reqid = response['Response']['RequestId']
|
442
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
443
|
+
end
|
444
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
445
|
+
raise e
|
446
|
+
rescue StandardError => e
|
447
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
448
|
+
end
|
449
|
+
|
450
|
+
# 创建弹性网卡
|
451
|
+
|
452
|
+
# @param request: Request instance for CreateNetworkInterface.
|
453
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateNetworkInterfaceRequest`
|
454
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateNetworkInterfaceResponse`
|
455
|
+
def CreateNetworkInterface(request)
|
456
|
+
body = send_request('CreateNetworkInterface', request.serialize)
|
457
|
+
response = JSON.parse(body)
|
458
|
+
if response['Response'].key?('Error') == false
|
459
|
+
model = CreateNetworkInterfaceResponse.new
|
460
|
+
model.deserialize(response['Response'])
|
461
|
+
model
|
462
|
+
else
|
463
|
+
code = response['Response']['Error']['Code']
|
464
|
+
message = response['Response']['Error']['Message']
|
465
|
+
reqid = response['Response']['RequestId']
|
466
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
467
|
+
end
|
468
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
469
|
+
raise e
|
470
|
+
rescue StandardError => e
|
471
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
472
|
+
end
|
473
|
+
|
474
|
+
# 创建了VPC后,系统会创建一个默认路由表,所有新建的子网都会关联到默认路由表。默认情况下您可以直接使用默认路由表来管理您的路由策略。当您的路由策略较多时,您可以调用创建路由表接口创建更多路由表管理您的路由策略。
|
475
|
+
|
476
|
+
# @param request: Request instance for CreateRouteTable.
|
477
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateRouteTableRequest`
|
478
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateRouteTableResponse`
|
479
|
+
def CreateRouteTable(request)
|
480
|
+
body = send_request('CreateRouteTable', request.serialize)
|
481
|
+
response = JSON.parse(body)
|
482
|
+
if response['Response'].key?('Error') == false
|
483
|
+
model = CreateRouteTableResponse.new
|
484
|
+
model.deserialize(response['Response'])
|
485
|
+
model
|
486
|
+
else
|
487
|
+
code = response['Response']['Error']['Code']
|
488
|
+
message = response['Response']['Error']['Message']
|
489
|
+
reqid = response['Response']['RequestId']
|
490
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
491
|
+
end
|
492
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
493
|
+
raise e
|
494
|
+
rescue StandardError => e
|
495
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
496
|
+
end
|
497
|
+
|
498
|
+
# 创建路由策略
|
499
|
+
|
500
|
+
# @param request: Request instance for CreateRoutes.
|
501
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateRoutesRequest`
|
502
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateRoutesResponse`
|
503
|
+
def CreateRoutes(request)
|
504
|
+
body = send_request('CreateRoutes', request.serialize)
|
505
|
+
response = JSON.parse(body)
|
506
|
+
if response['Response'].key?('Error') == false
|
507
|
+
model = CreateRoutesResponse.new
|
508
|
+
model.deserialize(response['Response'])
|
509
|
+
model
|
510
|
+
else
|
511
|
+
code = response['Response']['Error']['Code']
|
512
|
+
message = response['Response']['Error']['Message']
|
513
|
+
reqid = response['Response']['RequestId']
|
514
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
515
|
+
end
|
516
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
517
|
+
raise e
|
518
|
+
rescue StandardError => e
|
519
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
520
|
+
end
|
521
|
+
|
522
|
+
# 创建安全组
|
523
|
+
|
524
|
+
# @param request: Request instance for CreateSecurityGroup.
|
525
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateSecurityGroupRequest`
|
526
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateSecurityGroupResponse`
|
527
|
+
def CreateSecurityGroup(request)
|
528
|
+
body = send_request('CreateSecurityGroup', request.serialize)
|
529
|
+
response = JSON.parse(body)
|
530
|
+
if response['Response'].key?('Error') == false
|
531
|
+
model = CreateSecurityGroupResponse.new
|
532
|
+
model.deserialize(response['Response'])
|
533
|
+
model
|
534
|
+
else
|
535
|
+
code = response['Response']['Error']['Code']
|
536
|
+
message = response['Response']['Error']['Message']
|
537
|
+
reqid = response['Response']['RequestId']
|
538
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
539
|
+
end
|
540
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
541
|
+
raise e
|
542
|
+
rescue StandardError => e
|
543
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
544
|
+
end
|
545
|
+
|
546
|
+
# <p>本接口(CreateSecurityGroupPolicies)用于创建安全组规则(SecurityGroupPolicy)。</p>
|
547
|
+
# <p>在 SecurityGroupPolicySet 参数中:</p>
|
548
|
+
# <ul>
|
549
|
+
# <li>Version 安全组规则版本号,用户每次更新安全规则版本会自动加1,防止您更新的路由规则已过期,不填不考虑冲突。</li>
|
550
|
+
# <li>在创建出站和入站规则(Egress 和 Ingress)时:<ul>
|
551
|
+
# <li>Protocol 字段支持输入TCP, UDP, ICMP, GRE, ALL。</li>
|
552
|
+
# <li>CidrBlock 字段允许输入符合cidr格式标准的任意字符串。在基础网络中,如果 CidrBlock 包含您的账户内的云服务器之外的设备在腾讯云的内网 IP,并不代表此规则允许您访问这些设备,租户之间网络隔离规则优先于安全组中的内网规则。</li>
|
553
|
+
# <li>SecurityGroupId 字段允许输入与待修改的安全组位于相同项目中的安全组 ID,包括这个安全组 ID 本身,代表安全组下所有云服务器的内网 IP。使用这个字段时,这条规则用来匹配网络报文的过程中会随着被使用的这个 ID 所关联的云服务器变化而变化,不需要重新修改。</li>
|
554
|
+
# <li>Port 字段允许输入一个单独端口号,或者用减号分隔的两个端口号代表端口范围,例如80或8000-8010。只有当 Protocol 字段是 TCP 或 UDP 时,Port 字段才被接受,即 Protocol 字段不是 TCP 或 UDP 时,Protocol 和 Port 排他关系,不允许同时输入,否则会接口报错。</li>
|
555
|
+
# <li>Action 字段只允许输入 ACCEPT 或 DROP。</li>
|
556
|
+
# <li>CidrBlock, SecurityGroupId, AddressTemplate 是排他关系,不允许同时输入,Protocol + Port 和 ServiceTemplate 二者是排他关系,不允许同时输入。</li>
|
557
|
+
# <li>一次请求中只能创建单个方向的规则, 如果需要指定索引(PolicyIndex)参数, 多条规则的索引必须一致。</li>
|
558
|
+
# </ul></li></ul>
|
559
|
+
# <p>默认接口请求频率限制:20次/秒。</p>
|
560
|
+
|
561
|
+
# @param request: Request instance for CreateSecurityGroupPolicies.
|
562
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateSecurityGroupPoliciesRequest`
|
563
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateSecurityGroupPoliciesResponse`
|
564
|
+
def CreateSecurityGroupPolicies(request)
|
565
|
+
body = send_request('CreateSecurityGroupPolicies', request.serialize)
|
566
|
+
response = JSON.parse(body)
|
567
|
+
if response['Response'].key?('Error') == false
|
568
|
+
model = CreateSecurityGroupPoliciesResponse.new
|
569
|
+
model.deserialize(response['Response'])
|
570
|
+
model
|
571
|
+
else
|
572
|
+
code = response['Response']['Error']['Code']
|
573
|
+
message = response['Response']['Error']['Message']
|
574
|
+
reqid = response['Response']['RequestId']
|
575
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
576
|
+
end
|
577
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
578
|
+
raise e
|
579
|
+
rescue StandardError => e
|
580
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
581
|
+
end
|
582
|
+
|
583
|
+
# 创建子网,若创建成功,则此子网会成为此可用区的默认子网。
|
584
|
+
|
585
|
+
# @param request: Request instance for CreateSubnet.
|
586
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateSubnetRequest`
|
587
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateSubnetResponse`
|
588
|
+
def CreateSubnet(request)
|
589
|
+
body = send_request('CreateSubnet', request.serialize)
|
590
|
+
response = JSON.parse(body)
|
591
|
+
if response['Response'].key?('Error') == false
|
592
|
+
model = CreateSubnetResponse.new
|
593
|
+
model.deserialize(response['Response'])
|
594
|
+
model
|
595
|
+
else
|
596
|
+
code = response['Response']['Error']['Code']
|
597
|
+
message = response['Response']['Error']['Message']
|
598
|
+
reqid = response['Response']['RequestId']
|
599
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
600
|
+
end
|
601
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
602
|
+
raise e
|
603
|
+
rescue StandardError => e
|
604
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
605
|
+
end
|
606
|
+
|
607
|
+
# 创建私有网络
|
608
|
+
|
609
|
+
# @param request: Request instance for CreateVpc.
|
610
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::CreateVpcRequest`
|
611
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::CreateVpcResponse`
|
612
|
+
def CreateVpc(request)
|
613
|
+
body = send_request('CreateVpc', request.serialize)
|
614
|
+
response = JSON.parse(body)
|
615
|
+
if response['Response'].key?('Error') == false
|
616
|
+
model = CreateVpcResponse.new
|
617
|
+
model.deserialize(response['Response'])
|
618
|
+
model
|
619
|
+
else
|
620
|
+
code = response['Response']['Error']['Code']
|
621
|
+
message = response['Response']['Error']['Message']
|
622
|
+
reqid = response['Response']['RequestId']
|
623
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
624
|
+
end
|
625
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
626
|
+
raise e
|
627
|
+
rescue StandardError => e
|
628
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
629
|
+
end
|
630
|
+
|
631
|
+
# 用于删除高可用虚拟IP(HAVIP)
|
632
|
+
|
633
|
+
# @param request: Request instance for DeleteHaVip.
|
634
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteHaVipRequest`
|
635
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteHaVipResponse`
|
636
|
+
def DeleteHaVip(request)
|
637
|
+
body = send_request('DeleteHaVip', request.serialize)
|
638
|
+
response = JSON.parse(body)
|
639
|
+
if response['Response'].key?('Error') == false
|
640
|
+
model = DeleteHaVipResponse.new
|
641
|
+
model.deserialize(response['Response'])
|
642
|
+
model
|
643
|
+
else
|
644
|
+
code = response['Response']['Error']['Code']
|
645
|
+
message = response['Response']['Error']['Message']
|
646
|
+
reqid = response['Response']['RequestId']
|
647
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
648
|
+
end
|
649
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
650
|
+
raise e
|
651
|
+
rescue StandardError => e
|
652
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
653
|
+
end
|
654
|
+
|
655
|
+
# 删除镜像
|
656
|
+
|
657
|
+
# @param request: Request instance for DeleteImage.
|
658
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteImageRequest`
|
659
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteImageResponse`
|
660
|
+
def DeleteImage(request)
|
661
|
+
body = send_request('DeleteImage', request.serialize)
|
662
|
+
response = JSON.parse(body)
|
663
|
+
if response['Response'].key?('Error') == false
|
664
|
+
model = DeleteImageResponse.new
|
665
|
+
model.deserialize(response['Response'])
|
666
|
+
model
|
667
|
+
else
|
668
|
+
code = response['Response']['Error']['Code']
|
669
|
+
message = response['Response']['Error']['Message']
|
670
|
+
reqid = response['Response']['RequestId']
|
671
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
672
|
+
end
|
673
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
674
|
+
raise e
|
675
|
+
rescue StandardError => e
|
676
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
677
|
+
end
|
678
|
+
|
679
|
+
# 删除负载均衡监听器。
|
680
|
+
|
681
|
+
# @param request: Request instance for DeleteListener.
|
682
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteListenerRequest`
|
683
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteListenerResponse`
|
684
|
+
def DeleteListener(request)
|
685
|
+
body = send_request('DeleteListener', request.serialize)
|
686
|
+
response = JSON.parse(body)
|
687
|
+
if response['Response'].key?('Error') == false
|
688
|
+
model = DeleteListenerResponse.new
|
689
|
+
model.deserialize(response['Response'])
|
690
|
+
model
|
691
|
+
else
|
692
|
+
code = response['Response']['Error']['Code']
|
693
|
+
message = response['Response']['Error']['Message']
|
694
|
+
reqid = response['Response']['RequestId']
|
695
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
696
|
+
end
|
697
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
698
|
+
raise e
|
699
|
+
rescue StandardError => e
|
700
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
701
|
+
end
|
702
|
+
|
703
|
+
# 删除负载均衡实例。
|
704
|
+
|
705
|
+
# @param request: Request instance for DeleteLoadBalancer.
|
706
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteLoadBalancerRequest`
|
707
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteLoadBalancerResponse`
|
708
|
+
def DeleteLoadBalancer(request)
|
709
|
+
body = send_request('DeleteLoadBalancer', request.serialize)
|
710
|
+
response = JSON.parse(body)
|
711
|
+
if response['Response'].key?('Error') == false
|
712
|
+
model = DeleteLoadBalancerResponse.new
|
713
|
+
model.deserialize(response['Response'])
|
714
|
+
model
|
715
|
+
else
|
716
|
+
code = response['Response']['Error']['Code']
|
717
|
+
message = response['Response']['Error']['Message']
|
718
|
+
reqid = response['Response']['RequestId']
|
719
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
720
|
+
end
|
721
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
722
|
+
raise e
|
723
|
+
rescue StandardError => e
|
724
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
725
|
+
end
|
726
|
+
|
727
|
+
# 删除负载均衡多个监听器
|
728
|
+
|
729
|
+
# @param request: Request instance for DeleteLoadBalancerListeners.
|
730
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteLoadBalancerListenersRequest`
|
731
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteLoadBalancerListenersResponse`
|
732
|
+
def DeleteLoadBalancerListeners(request)
|
733
|
+
body = send_request('DeleteLoadBalancerListeners', request.serialize)
|
734
|
+
response = JSON.parse(body)
|
735
|
+
if response['Response'].key?('Error') == false
|
736
|
+
model = DeleteLoadBalancerListenersResponse.new
|
737
|
+
model.deserialize(response['Response'])
|
738
|
+
model
|
739
|
+
else
|
740
|
+
code = response['Response']['Error']['Code']
|
741
|
+
message = response['Response']['Error']['Message']
|
742
|
+
reqid = response['Response']['RequestId']
|
743
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
744
|
+
end
|
745
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
746
|
+
raise e
|
747
|
+
rescue StandardError => e
|
748
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
749
|
+
end
|
750
|
+
|
751
|
+
# 删除业务模块
|
752
|
+
|
753
|
+
# @param request: Request instance for DeleteModule.
|
754
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteModuleRequest`
|
755
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteModuleResponse`
|
756
|
+
def DeleteModule(request)
|
757
|
+
body = send_request('DeleteModule', request.serialize)
|
758
|
+
response = JSON.parse(body)
|
759
|
+
if response['Response'].key?('Error') == false
|
760
|
+
model = DeleteModuleResponse.new
|
761
|
+
model.deserialize(response['Response'])
|
762
|
+
model
|
763
|
+
else
|
764
|
+
code = response['Response']['Error']['Code']
|
765
|
+
message = response['Response']['Error']['Message']
|
766
|
+
reqid = response['Response']['RequestId']
|
767
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
768
|
+
end
|
769
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
770
|
+
raise e
|
771
|
+
rescue StandardError => e
|
772
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
773
|
+
end
|
774
|
+
|
775
|
+
# 删除弹性网卡
|
776
|
+
|
777
|
+
# @param request: Request instance for DeleteNetworkInterface.
|
778
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteNetworkInterfaceRequest`
|
779
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteNetworkInterfaceResponse`
|
780
|
+
def DeleteNetworkInterface(request)
|
781
|
+
body = send_request('DeleteNetworkInterface', request.serialize)
|
782
|
+
response = JSON.parse(body)
|
783
|
+
if response['Response'].key?('Error') == false
|
784
|
+
model = DeleteNetworkInterfaceResponse.new
|
785
|
+
model.deserialize(response['Response'])
|
786
|
+
model
|
787
|
+
else
|
788
|
+
code = response['Response']['Error']['Code']
|
789
|
+
message = response['Response']['Error']['Message']
|
790
|
+
reqid = response['Response']['RequestId']
|
791
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
792
|
+
end
|
793
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
794
|
+
raise e
|
795
|
+
rescue StandardError => e
|
796
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
797
|
+
end
|
798
|
+
|
799
|
+
# 删除路由表
|
800
|
+
|
801
|
+
# @param request: Request instance for DeleteRouteTable.
|
802
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteRouteTableRequest`
|
803
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteRouteTableResponse`
|
804
|
+
def DeleteRouteTable(request)
|
805
|
+
body = send_request('DeleteRouteTable', request.serialize)
|
806
|
+
response = JSON.parse(body)
|
807
|
+
if response['Response'].key?('Error') == false
|
808
|
+
model = DeleteRouteTableResponse.new
|
809
|
+
model.deserialize(response['Response'])
|
810
|
+
model
|
811
|
+
else
|
812
|
+
code = response['Response']['Error']['Code']
|
813
|
+
message = response['Response']['Error']['Message']
|
814
|
+
reqid = response['Response']['RequestId']
|
815
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
816
|
+
end
|
817
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
818
|
+
raise e
|
819
|
+
rescue StandardError => e
|
820
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
821
|
+
end
|
822
|
+
|
823
|
+
# 对某个路由表批量删除路由策略
|
824
|
+
|
825
|
+
# @param request: Request instance for DeleteRoutes.
|
826
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteRoutesRequest`
|
827
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteRoutesResponse`
|
828
|
+
def DeleteRoutes(request)
|
829
|
+
body = send_request('DeleteRoutes', request.serialize)
|
830
|
+
response = JSON.parse(body)
|
831
|
+
if response['Response'].key?('Error') == false
|
832
|
+
model = DeleteRoutesResponse.new
|
833
|
+
model.deserialize(response['Response'])
|
834
|
+
model
|
835
|
+
else
|
836
|
+
code = response['Response']['Error']['Code']
|
837
|
+
message = response['Response']['Error']['Message']
|
838
|
+
reqid = response['Response']['RequestId']
|
839
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
840
|
+
end
|
841
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
842
|
+
raise e
|
843
|
+
rescue StandardError => e
|
844
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
845
|
+
end
|
846
|
+
|
847
|
+
# 只有当前账号下的安全组允许被删除。
|
848
|
+
# 安全组实例ID如果在其他安全组的规则中被引用,则无法直接删除。这种情况下,需要先进行规则修改,再删除安全组。
|
849
|
+
# 删除的安全组无法再找回,请谨慎调用。
|
850
|
+
|
851
|
+
# @param request: Request instance for DeleteSecurityGroup.
|
852
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteSecurityGroupRequest`
|
853
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteSecurityGroupResponse`
|
854
|
+
def DeleteSecurityGroup(request)
|
855
|
+
body = send_request('DeleteSecurityGroup', request.serialize)
|
856
|
+
response = JSON.parse(body)
|
857
|
+
if response['Response'].key?('Error') == false
|
858
|
+
model = DeleteSecurityGroupResponse.new
|
859
|
+
model.deserialize(response['Response'])
|
860
|
+
model
|
861
|
+
else
|
862
|
+
code = response['Response']['Error']['Code']
|
863
|
+
message = response['Response']['Error']['Message']
|
864
|
+
reqid = response['Response']['RequestId']
|
865
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
866
|
+
end
|
867
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
868
|
+
raise e
|
869
|
+
rescue StandardError => e
|
870
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
871
|
+
end
|
872
|
+
|
873
|
+
# SecurityGroupPolicySet.Version 用于指定要操作的安全组的版本。传入 Version 版本号若不等于当前安全组的最新版本,将返回失败;若不传 Version 则直接删除指定PolicyIndex的规则。
|
874
|
+
|
875
|
+
# @param request: Request instance for DeleteSecurityGroupPolicies.
|
876
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteSecurityGroupPoliciesRequest`
|
877
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteSecurityGroupPoliciesResponse`
|
878
|
+
def DeleteSecurityGroupPolicies(request)
|
879
|
+
body = send_request('DeleteSecurityGroupPolicies', request.serialize)
|
880
|
+
response = JSON.parse(body)
|
881
|
+
if response['Response'].key?('Error') == false
|
882
|
+
model = DeleteSecurityGroupPoliciesResponse.new
|
883
|
+
model.deserialize(response['Response'])
|
884
|
+
model
|
885
|
+
else
|
886
|
+
code = response['Response']['Error']['Code']
|
887
|
+
message = response['Response']['Error']['Message']
|
888
|
+
reqid = response['Response']['RequestId']
|
889
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
890
|
+
end
|
891
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
892
|
+
raise e
|
893
|
+
rescue StandardError => e
|
894
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
895
|
+
end
|
896
|
+
|
897
|
+
# 本接口(DeleteSnapshots)用于删除快照。
|
898
|
+
|
899
|
+
# * 快照必须处于NORMAL状态,快照状态可以通过[DescribeSnapshots](/document/product/362/15647)接口查询,见输出参数中SnapshotState字段解释。
|
900
|
+
# * 支持批量操作。如果多个快照存在无法删除的快照,则操作不执行,以返回特定的错误码返回。
|
901
|
+
|
902
|
+
# @param request: Request instance for DeleteSnapshots.
|
903
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteSnapshotsRequest`
|
904
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteSnapshotsResponse`
|
905
|
+
def DeleteSnapshots(request)
|
906
|
+
body = send_request('DeleteSnapshots', request.serialize)
|
907
|
+
response = JSON.parse(body)
|
908
|
+
if response['Response'].key?('Error') == false
|
909
|
+
model = DeleteSnapshotsResponse.new
|
910
|
+
model.deserialize(response['Response'])
|
911
|
+
model
|
912
|
+
else
|
913
|
+
code = response['Response']['Error']['Code']
|
914
|
+
message = response['Response']['Error']['Message']
|
915
|
+
reqid = response['Response']['RequestId']
|
916
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
917
|
+
end
|
918
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
919
|
+
raise e
|
920
|
+
rescue StandardError => e
|
921
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
922
|
+
end
|
923
|
+
|
924
|
+
# 删除子网,若子网为可用区下的默认子网,则默认子网会回退到系统自动创建的默认子网,非用户最新创建的子网。若默认子网不满足需求,可调用设置默认子网接口设置。
|
925
|
+
|
926
|
+
# @param request: Request instance for DeleteSubnet.
|
927
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteSubnetRequest`
|
928
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteSubnetResponse`
|
929
|
+
def DeleteSubnet(request)
|
930
|
+
body = send_request('DeleteSubnet', request.serialize)
|
931
|
+
response = JSON.parse(body)
|
932
|
+
if response['Response'].key?('Error') == false
|
933
|
+
model = DeleteSubnetResponse.new
|
934
|
+
model.deserialize(response['Response'])
|
935
|
+
model
|
936
|
+
else
|
937
|
+
code = response['Response']['Error']['Code']
|
938
|
+
message = response['Response']['Error']['Message']
|
939
|
+
reqid = response['Response']['RequestId']
|
940
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
941
|
+
end
|
942
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
943
|
+
raise e
|
944
|
+
rescue StandardError => e
|
945
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
946
|
+
end
|
947
|
+
|
948
|
+
# 删除私有网络
|
949
|
+
|
950
|
+
# @param request: Request instance for DeleteVpc.
|
951
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DeleteVpcRequest`
|
952
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DeleteVpcResponse`
|
953
|
+
def DeleteVpc(request)
|
954
|
+
body = send_request('DeleteVpc', request.serialize)
|
955
|
+
response = JSON.parse(body)
|
956
|
+
if response['Response'].key?('Error') == false
|
957
|
+
model = DeleteVpcResponse.new
|
958
|
+
model.deserialize(response['Response'])
|
959
|
+
model
|
960
|
+
else
|
961
|
+
code = response['Response']['Error']['Code']
|
962
|
+
message = response['Response']['Error']['Message']
|
963
|
+
reqid = response['Response']['RequestId']
|
964
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
965
|
+
end
|
966
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
967
|
+
raise e
|
968
|
+
rescue StandardError => e
|
969
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
970
|
+
end
|
971
|
+
|
972
|
+
# 查询您账户的弹性公网IP(简称 EIP)在当前地域的配额信息
|
973
|
+
|
974
|
+
# @param request: Request instance for DescribeAddressQuota.
|
975
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeAddressQuotaRequest`
|
976
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeAddressQuotaResponse`
|
977
|
+
def DescribeAddressQuota(request)
|
978
|
+
body = send_request('DescribeAddressQuota', request.serialize)
|
979
|
+
response = JSON.parse(body)
|
980
|
+
if response['Response'].key?('Error') == false
|
981
|
+
model = DescribeAddressQuotaResponse.new
|
982
|
+
model.deserialize(response['Response'])
|
983
|
+
model
|
984
|
+
else
|
985
|
+
code = response['Response']['Error']['Code']
|
986
|
+
message = response['Response']['Error']['Message']
|
987
|
+
reqid = response['Response']['RequestId']
|
988
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
989
|
+
end
|
990
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
991
|
+
raise e
|
992
|
+
rescue StandardError => e
|
993
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
994
|
+
end
|
995
|
+
|
996
|
+
# 查询弹性公网IP列表
|
997
|
+
|
998
|
+
# @param request: Request instance for DescribeAddresses.
|
999
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeAddressesRequest`
|
1000
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeAddressesResponse`
|
1001
|
+
def DescribeAddresses(request)
|
1002
|
+
body = send_request('DescribeAddresses', request.serialize)
|
1003
|
+
response = JSON.parse(body)
|
1004
|
+
if response['Response'].key?('Error') == false
|
1005
|
+
model = DescribeAddressesResponse.new
|
1006
|
+
model.deserialize(response['Response'])
|
1007
|
+
model
|
1008
|
+
else
|
1009
|
+
code = response['Response']['Error']['Code']
|
1010
|
+
message = response['Response']['Error']['Message']
|
1011
|
+
reqid = response['Response']['RequestId']
|
1012
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1013
|
+
end
|
1014
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1015
|
+
raise e
|
1016
|
+
rescue StandardError => e
|
1017
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1018
|
+
end
|
1019
|
+
|
1020
|
+
# 获取概览页统计的基本数据
|
1021
|
+
|
1022
|
+
# @param request: Request instance for DescribeBaseOverview.
|
1023
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeBaseOverviewRequest`
|
1024
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeBaseOverviewResponse`
|
1025
|
+
def DescribeBaseOverview(request)
|
1026
|
+
body = send_request('DescribeBaseOverview', request.serialize)
|
1027
|
+
response = JSON.parse(body)
|
1028
|
+
if response['Response'].key?('Error') == false
|
1029
|
+
model = DescribeBaseOverviewResponse.new
|
1030
|
+
model.deserialize(response['Response'])
|
1031
|
+
model
|
1032
|
+
else
|
1033
|
+
code = response['Response']['Error']['Code']
|
1034
|
+
message = response['Response']['Error']['Message']
|
1035
|
+
reqid = response['Response']['RequestId']
|
1036
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1037
|
+
end
|
1038
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1039
|
+
raise e
|
1040
|
+
rescue StandardError => e
|
1041
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1042
|
+
end
|
1043
|
+
|
1044
|
+
# 获取带宽硬盘等数据的限制
|
1045
|
+
|
1046
|
+
# @param request: Request instance for DescribeConfig.
|
1047
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeConfigRequest`
|
1048
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeConfigResponse`
|
1049
|
+
def DescribeConfig(request)
|
1050
|
+
body = send_request('DescribeConfig', request.serialize)
|
1051
|
+
response = JSON.parse(body)
|
1052
|
+
if response['Response'].key?('Error') == false
|
1053
|
+
model = DescribeConfigResponse.new
|
1054
|
+
model.deserialize(response['Response'])
|
1055
|
+
model
|
1056
|
+
else
|
1057
|
+
code = response['Response']['Error']['Code']
|
1058
|
+
message = response['Response']['Error']['Message']
|
1059
|
+
reqid = response['Response']['RequestId']
|
1060
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1061
|
+
end
|
1062
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1063
|
+
raise e
|
1064
|
+
rescue StandardError => e
|
1065
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1066
|
+
end
|
1067
|
+
|
1068
|
+
# 查询导入镜像任务
|
1069
|
+
|
1070
|
+
# @param request: Request instance for DescribeCustomImageTask.
|
1071
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeCustomImageTaskRequest`
|
1072
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeCustomImageTaskResponse`
|
1073
|
+
def DescribeCustomImageTask(request)
|
1074
|
+
body = send_request('DescribeCustomImageTask', request.serialize)
|
1075
|
+
response = JSON.parse(body)
|
1076
|
+
if response['Response'].key?('Error') == false
|
1077
|
+
model = DescribeCustomImageTaskResponse.new
|
1078
|
+
model.deserialize(response['Response'])
|
1079
|
+
model
|
1080
|
+
else
|
1081
|
+
code = response['Response']['Error']['Code']
|
1082
|
+
message = response['Response']['Error']['Message']
|
1083
|
+
reqid = response['Response']['RequestId']
|
1084
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1085
|
+
end
|
1086
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1087
|
+
raise e
|
1088
|
+
rescue StandardError => e
|
1089
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1090
|
+
end
|
1091
|
+
|
1092
|
+
# 查询可用区的默认子网
|
1093
|
+
|
1094
|
+
# @param request: Request instance for DescribeDefaultSubnet.
|
1095
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeDefaultSubnetRequest`
|
1096
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeDefaultSubnetResponse`
|
1097
|
+
def DescribeDefaultSubnet(request)
|
1098
|
+
body = send_request('DescribeDefaultSubnet', request.serialize)
|
1099
|
+
response = JSON.parse(body)
|
1100
|
+
if response['Response'].key?('Error') == false
|
1101
|
+
model = DescribeDefaultSubnetResponse.new
|
1102
|
+
model.deserialize(response['Response'])
|
1103
|
+
model
|
1104
|
+
else
|
1105
|
+
code = response['Response']['Error']['Code']
|
1106
|
+
message = response['Response']['Error']['Message']
|
1107
|
+
reqid = response['Response']['RequestId']
|
1108
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1109
|
+
end
|
1110
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1111
|
+
raise e
|
1112
|
+
rescue StandardError => e
|
1113
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1114
|
+
end
|
1115
|
+
|
1116
|
+
# 本接口(DescribeDisks)用于查询云硬盘列表。
|
1117
|
+
|
1118
|
+
# * 可以根据云硬盘ID、云硬盘类型或者云硬盘状态等信息来查询云硬盘的详细信息,不同条件之间为与(AND)的关系,过滤信息详细请见过滤器`Filter`。
|
1119
|
+
# * 如果参数为空,返回当前用户一定数量(`Limit`所指定的数量,默认为20)的云硬盘列表。
|
1120
|
+
|
1121
|
+
# @param request: Request instance for DescribeDisks.
|
1122
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeDisksRequest`
|
1123
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeDisksResponse`
|
1124
|
+
def DescribeDisks(request)
|
1125
|
+
body = send_request('DescribeDisks', request.serialize)
|
1126
|
+
response = JSON.parse(body)
|
1127
|
+
if response['Response'].key?('Error') == false
|
1128
|
+
model = DescribeDisksResponse.new
|
1129
|
+
model.deserialize(response['Response'])
|
1130
|
+
model
|
1131
|
+
else
|
1132
|
+
code = response['Response']['Error']['Code']
|
1133
|
+
message = response['Response']['Error']['Message']
|
1134
|
+
reqid = response['Response']['RequestId']
|
1135
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1136
|
+
end
|
1137
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1138
|
+
raise e
|
1139
|
+
rescue StandardError => e
|
1140
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1141
|
+
end
|
1142
|
+
|
1143
|
+
# 用于查询高可用虚拟IP(HAVIP)列表。
|
1144
|
+
|
1145
|
+
# @param request: Request instance for DescribeHaVips.
|
1146
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeHaVipsRequest`
|
1147
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeHaVipsResponse`
|
1148
|
+
def DescribeHaVips(request)
|
1149
|
+
body = send_request('DescribeHaVips', request.serialize)
|
1150
|
+
response = JSON.parse(body)
|
1151
|
+
if response['Response'].key?('Error') == false
|
1152
|
+
model = DescribeHaVipsResponse.new
|
1153
|
+
model.deserialize(response['Response'])
|
1154
|
+
model
|
1155
|
+
else
|
1156
|
+
code = response['Response']['Error']['Code']
|
1157
|
+
message = response['Response']['Error']['Message']
|
1158
|
+
reqid = response['Response']['RequestId']
|
1159
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1160
|
+
end
|
1161
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1162
|
+
raise e
|
1163
|
+
rescue StandardError => e
|
1164
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1165
|
+
end
|
1166
|
+
|
1167
|
+
# 展示镜像列表
|
1168
|
+
|
1169
|
+
# @param request: Request instance for DescribeImage.
|
1170
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeImageRequest`
|
1171
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeImageResponse`
|
1172
|
+
def DescribeImage(request)
|
1173
|
+
body = send_request('DescribeImage', request.serialize)
|
1174
|
+
response = JSON.parse(body)
|
1175
|
+
if response['Response'].key?('Error') == false
|
1176
|
+
model = DescribeImageResponse.new
|
1177
|
+
model.deserialize(response['Response'])
|
1178
|
+
model
|
1179
|
+
else
|
1180
|
+
code = response['Response']['Error']['Code']
|
1181
|
+
message = response['Response']['Error']['Message']
|
1182
|
+
reqid = response['Response']['RequestId']
|
1183
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1184
|
+
end
|
1185
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1186
|
+
raise e
|
1187
|
+
rescue StandardError => e
|
1188
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1189
|
+
end
|
1190
|
+
|
1191
|
+
# 查询外部导入镜像支持的OS列表
|
1192
|
+
|
1193
|
+
# @param request: Request instance for DescribeImportImageOs.
|
1194
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeImportImageOsRequest`
|
1195
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeImportImageOsResponse`
|
1196
|
+
def DescribeImportImageOs(request)
|
1197
|
+
body = send_request('DescribeImportImageOs', request.serialize)
|
1198
|
+
response = JSON.parse(body)
|
1199
|
+
if response['Response'].key?('Error') == false
|
1200
|
+
model = DescribeImportImageOsResponse.new
|
1201
|
+
model.deserialize(response['Response'])
|
1202
|
+
model
|
1203
|
+
else
|
1204
|
+
code = response['Response']['Error']['Code']
|
1205
|
+
message = response['Response']['Error']['Message']
|
1206
|
+
reqid = response['Response']['RequestId']
|
1207
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1208
|
+
end
|
1209
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1210
|
+
raise e
|
1211
|
+
rescue StandardError => e
|
1212
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1213
|
+
end
|
1214
|
+
|
1215
|
+
# 获取机型配置列表
|
1216
|
+
|
1217
|
+
# @param request: Request instance for DescribeInstanceTypeConfig.
|
1218
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeInstanceTypeConfigRequest`
|
1219
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeInstanceTypeConfigResponse`
|
1220
|
+
def DescribeInstanceTypeConfig(request)
|
1221
|
+
body = send_request('DescribeInstanceTypeConfig', request.serialize)
|
1222
|
+
response = JSON.parse(body)
|
1223
|
+
if response['Response'].key?('Error') == false
|
1224
|
+
model = DescribeInstanceTypeConfigResponse.new
|
1225
|
+
model.deserialize(response['Response'])
|
1226
|
+
model
|
1227
|
+
else
|
1228
|
+
code = response['Response']['Error']['Code']
|
1229
|
+
message = response['Response']['Error']['Message']
|
1230
|
+
reqid = response['Response']['RequestId']
|
1231
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1232
|
+
end
|
1233
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1234
|
+
raise e
|
1235
|
+
rescue StandardError => e
|
1236
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1237
|
+
end
|
1238
|
+
|
1239
|
+
# 查询实例管理终端地址
|
1240
|
+
|
1241
|
+
# @param request: Request instance for DescribeInstanceVncUrl.
|
1242
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeInstanceVncUrlRequest`
|
1243
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeInstanceVncUrlResponse`
|
1244
|
+
def DescribeInstanceVncUrl(request)
|
1245
|
+
body = send_request('DescribeInstanceVncUrl', request.serialize)
|
1246
|
+
response = JSON.parse(body)
|
1247
|
+
if response['Response'].key?('Error') == false
|
1248
|
+
model = DescribeInstanceVncUrlResponse.new
|
1249
|
+
model.deserialize(response['Response'])
|
1250
|
+
model
|
1251
|
+
else
|
1252
|
+
code = response['Response']['Error']['Code']
|
1253
|
+
message = response['Response']['Error']['Message']
|
1254
|
+
reqid = response['Response']['RequestId']
|
1255
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1256
|
+
end
|
1257
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1258
|
+
raise e
|
1259
|
+
rescue StandardError => e
|
1260
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1261
|
+
end
|
1262
|
+
|
1263
|
+
# 获取实例的相关信息。
|
1264
|
+
|
1265
|
+
# @param request: Request instance for DescribeInstances.
|
1266
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeInstancesRequest`
|
1267
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeInstancesResponse`
|
1268
|
+
def DescribeInstances(request)
|
1269
|
+
body = send_request('DescribeInstances', request.serialize)
|
1270
|
+
response = JSON.parse(body)
|
1271
|
+
if response['Response'].key?('Error') == false
|
1272
|
+
model = DescribeInstancesResponse.new
|
1273
|
+
model.deserialize(response['Response'])
|
1274
|
+
model
|
1275
|
+
else
|
1276
|
+
code = response['Response']['Error']['Code']
|
1277
|
+
message = response['Response']['Error']['Message']
|
1278
|
+
reqid = response['Response']['RequestId']
|
1279
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1280
|
+
end
|
1281
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1282
|
+
raise e
|
1283
|
+
rescue StandardError => e
|
1284
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1285
|
+
end
|
1286
|
+
|
1287
|
+
# 通过实例id获取当前禁止的操作
|
1288
|
+
|
1289
|
+
# @param request: Request instance for DescribeInstancesDeniedActions.
|
1290
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeInstancesDeniedActionsRequest`
|
1291
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeInstancesDeniedActionsResponse`
|
1292
|
+
def DescribeInstancesDeniedActions(request)
|
1293
|
+
body = send_request('DescribeInstancesDeniedActions', request.serialize)
|
1294
|
+
response = JSON.parse(body)
|
1295
|
+
if response['Response'].key?('Error') == false
|
1296
|
+
model = DescribeInstancesDeniedActionsResponse.new
|
1297
|
+
model.deserialize(response['Response'])
|
1298
|
+
model
|
1299
|
+
else
|
1300
|
+
code = response['Response']['Error']['Code']
|
1301
|
+
message = response['Response']['Error']['Message']
|
1302
|
+
reqid = response['Response']['RequestId']
|
1303
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1304
|
+
end
|
1305
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1306
|
+
raise e
|
1307
|
+
rescue StandardError => e
|
1308
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1309
|
+
end
|
1310
|
+
|
1311
|
+
# 查询负载均衡的监听器列表。
|
1312
|
+
|
1313
|
+
# @param request: Request instance for DescribeListeners.
|
1314
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeListenersRequest`
|
1315
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeListenersResponse`
|
1316
|
+
def DescribeListeners(request)
|
1317
|
+
body = send_request('DescribeListeners', request.serialize)
|
1318
|
+
response = JSON.parse(body)
|
1319
|
+
if response['Response'].key?('Error') == false
|
1320
|
+
model = DescribeListenersResponse.new
|
1321
|
+
model.deserialize(response['Response'])
|
1322
|
+
model
|
1323
|
+
else
|
1324
|
+
code = response['Response']['Error']['Code']
|
1325
|
+
message = response['Response']['Error']['Message']
|
1326
|
+
reqid = response['Response']['RequestId']
|
1327
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1328
|
+
end
|
1329
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1330
|
+
raise e
|
1331
|
+
rescue StandardError => e
|
1332
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1333
|
+
end
|
1334
|
+
|
1335
|
+
# 查询负载均衡相关的任务状态
|
1336
|
+
|
1337
|
+
# @param request: Request instance for DescribeLoadBalanceTaskStatus.
|
1338
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeLoadBalanceTaskStatusRequest`
|
1339
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeLoadBalanceTaskStatusResponse`
|
1340
|
+
def DescribeLoadBalanceTaskStatus(request)
|
1341
|
+
body = send_request('DescribeLoadBalanceTaskStatus', request.serialize)
|
1342
|
+
response = JSON.parse(body)
|
1343
|
+
if response['Response'].key?('Error') == false
|
1344
|
+
model = DescribeLoadBalanceTaskStatusResponse.new
|
1345
|
+
model.deserialize(response['Response'])
|
1346
|
+
model
|
1347
|
+
else
|
1348
|
+
code = response['Response']['Error']['Code']
|
1349
|
+
message = response['Response']['Error']['Message']
|
1350
|
+
reqid = response['Response']['RequestId']
|
1351
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1352
|
+
end
|
1353
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1354
|
+
raise e
|
1355
|
+
rescue StandardError => e
|
1356
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1357
|
+
end
|
1358
|
+
|
1359
|
+
# 查询负载均衡实例列表。
|
1360
|
+
|
1361
|
+
# @param request: Request instance for DescribeLoadBalancers.
|
1362
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeLoadBalancersRequest`
|
1363
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeLoadBalancersResponse`
|
1364
|
+
def DescribeLoadBalancers(request)
|
1365
|
+
body = send_request('DescribeLoadBalancers', request.serialize)
|
1366
|
+
response = JSON.parse(body)
|
1367
|
+
if response['Response'].key?('Error') == false
|
1368
|
+
model = DescribeLoadBalancersResponse.new
|
1369
|
+
model.deserialize(response['Response'])
|
1370
|
+
model
|
1371
|
+
else
|
1372
|
+
code = response['Response']['Error']['Code']
|
1373
|
+
message = response['Response']['Error']['Message']
|
1374
|
+
reqid = response['Response']['RequestId']
|
1375
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1376
|
+
end
|
1377
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1378
|
+
raise e
|
1379
|
+
rescue StandardError => e
|
1380
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1381
|
+
end
|
1382
|
+
|
1383
|
+
# 获取模块列表
|
1384
|
+
|
1385
|
+
# @param request: Request instance for DescribeModule.
|
1386
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeModuleRequest`
|
1387
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeModuleResponse`
|
1388
|
+
def DescribeModule(request)
|
1389
|
+
body = send_request('DescribeModule', request.serialize)
|
1390
|
+
response = JSON.parse(body)
|
1391
|
+
if response['Response'].key?('Error') == false
|
1392
|
+
model = DescribeModuleResponse.new
|
1393
|
+
model.deserialize(response['Response'])
|
1394
|
+
model
|
1395
|
+
else
|
1396
|
+
code = response['Response']['Error']['Code']
|
1397
|
+
message = response['Response']['Error']['Message']
|
1398
|
+
reqid = response['Response']['RequestId']
|
1399
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1400
|
+
end
|
1401
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1402
|
+
raise e
|
1403
|
+
rescue StandardError => e
|
1404
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1405
|
+
end
|
1406
|
+
|
1407
|
+
# 展示模块详细信息
|
1408
|
+
|
1409
|
+
# @param request: Request instance for DescribeModuleDetail.
|
1410
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeModuleDetailRequest`
|
1411
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeModuleDetailResponse`
|
1412
|
+
def DescribeModuleDetail(request)
|
1413
|
+
body = send_request('DescribeModuleDetail', request.serialize)
|
1414
|
+
response = JSON.parse(body)
|
1415
|
+
if response['Response'].key?('Error') == false
|
1416
|
+
model = DescribeModuleDetailResponse.new
|
1417
|
+
model.deserialize(response['Response'])
|
1418
|
+
model
|
1419
|
+
else
|
1420
|
+
code = response['Response']['Error']['Code']
|
1421
|
+
message = response['Response']['Error']['Message']
|
1422
|
+
reqid = response['Response']['RequestId']
|
1423
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1424
|
+
end
|
1425
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1426
|
+
raise e
|
1427
|
+
rescue StandardError => e
|
1428
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1429
|
+
end
|
1430
|
+
|
1431
|
+
# 获取客户节点上的出入带宽月峰和计费带宽信息
|
1432
|
+
|
1433
|
+
# @param request: Request instance for DescribeMonthPeakNetwork.
|
1434
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeMonthPeakNetworkRequest`
|
1435
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeMonthPeakNetworkResponse`
|
1436
|
+
def DescribeMonthPeakNetwork(request)
|
1437
|
+
body = send_request('DescribeMonthPeakNetwork', request.serialize)
|
1438
|
+
response = JSON.parse(body)
|
1439
|
+
if response['Response'].key?('Error') == false
|
1440
|
+
model = DescribeMonthPeakNetworkResponse.new
|
1441
|
+
model.deserialize(response['Response'])
|
1442
|
+
model
|
1443
|
+
else
|
1444
|
+
code = response['Response']['Error']['Code']
|
1445
|
+
message = response['Response']['Error']['Message']
|
1446
|
+
reqid = response['Response']['RequestId']
|
1447
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1448
|
+
end
|
1449
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1450
|
+
raise e
|
1451
|
+
rescue StandardError => e
|
1452
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1453
|
+
end
|
1454
|
+
|
1455
|
+
# 查询弹性网卡列表
|
1456
|
+
|
1457
|
+
# @param request: Request instance for DescribeNetworkInterfaces.
|
1458
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeNetworkInterfacesRequest`
|
1459
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeNetworkInterfacesResponse`
|
1460
|
+
def DescribeNetworkInterfaces(request)
|
1461
|
+
body = send_request('DescribeNetworkInterfaces', request.serialize)
|
1462
|
+
response = JSON.parse(body)
|
1463
|
+
if response['Response'].key?('Error') == false
|
1464
|
+
model = DescribeNetworkInterfacesResponse.new
|
1465
|
+
model.deserialize(response['Response'])
|
1466
|
+
model
|
1467
|
+
else
|
1468
|
+
code = response['Response']['Error']['Code']
|
1469
|
+
message = response['Response']['Error']['Message']
|
1470
|
+
reqid = response['Response']['RequestId']
|
1471
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1472
|
+
end
|
1473
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1474
|
+
raise e
|
1475
|
+
rescue StandardError => e
|
1476
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1477
|
+
end
|
1478
|
+
|
1479
|
+
# 获取节点列表
|
1480
|
+
|
1481
|
+
# @param request: Request instance for DescribeNode.
|
1482
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeNodeRequest`
|
1483
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeNodeResponse`
|
1484
|
+
def DescribeNode(request)
|
1485
|
+
body = send_request('DescribeNode', request.serialize)
|
1486
|
+
response = JSON.parse(body)
|
1487
|
+
if response['Response'].key?('Error') == false
|
1488
|
+
model = DescribeNodeResponse.new
|
1489
|
+
model.deserialize(response['Response'])
|
1490
|
+
model
|
1491
|
+
else
|
1492
|
+
code = response['Response']['Error']['Code']
|
1493
|
+
message = response['Response']['Error']['Message']
|
1494
|
+
reqid = response['Response']['RequestId']
|
1495
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1496
|
+
end
|
1497
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1498
|
+
raise e
|
1499
|
+
rescue StandardError => e
|
1500
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1501
|
+
end
|
1502
|
+
|
1503
|
+
# 使用本接口获取某种机型在某些区域的装箱配额(当使用虚拟机型时,返回的是一组相互关联的装箱配额)。
|
1504
|
+
|
1505
|
+
# @param request: Request instance for DescribePackingQuotaGroup.
|
1506
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribePackingQuotaGroupRequest`
|
1507
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribePackingQuotaGroupResponse`
|
1508
|
+
def DescribePackingQuotaGroup(request)
|
1509
|
+
body = send_request('DescribePackingQuotaGroup', request.serialize)
|
1510
|
+
response = JSON.parse(body)
|
1511
|
+
if response['Response'].key?('Error') == false
|
1512
|
+
model = DescribePackingQuotaGroupResponse.new
|
1513
|
+
model.deserialize(response['Response'])
|
1514
|
+
model
|
1515
|
+
else
|
1516
|
+
code = response['Response']['Error']['Code']
|
1517
|
+
message = response['Response']['Error']['Message']
|
1518
|
+
reqid = response['Response']['RequestId']
|
1519
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1520
|
+
end
|
1521
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1522
|
+
raise e
|
1523
|
+
rescue StandardError => e
|
1524
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1525
|
+
end
|
1526
|
+
|
1527
|
+
# CPU 内存 硬盘等基础信息峰值数据
|
1528
|
+
|
1529
|
+
# @param request: Request instance for DescribePeakBaseOverview.
|
1530
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribePeakBaseOverviewRequest`
|
1531
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribePeakBaseOverviewResponse`
|
1532
|
+
def DescribePeakBaseOverview(request)
|
1533
|
+
body = send_request('DescribePeakBaseOverview', request.serialize)
|
1534
|
+
response = JSON.parse(body)
|
1535
|
+
if response['Response'].key?('Error') == false
|
1536
|
+
model = DescribePeakBaseOverviewResponse.new
|
1537
|
+
model.deserialize(response['Response'])
|
1538
|
+
model
|
1539
|
+
else
|
1540
|
+
code = response['Response']['Error']['Code']
|
1541
|
+
message = response['Response']['Error']['Message']
|
1542
|
+
reqid = response['Response']['RequestId']
|
1543
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1544
|
+
end
|
1545
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1546
|
+
raise e
|
1547
|
+
rescue StandardError => e
|
1548
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1549
|
+
end
|
1550
|
+
|
1551
|
+
# 获取网络峰值数据
|
1552
|
+
|
1553
|
+
# @param request: Request instance for DescribePeakNetworkOverview.
|
1554
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribePeakNetworkOverviewRequest`
|
1555
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribePeakNetworkOverviewResponse`
|
1556
|
+
def DescribePeakNetworkOverview(request)
|
1557
|
+
body = send_request('DescribePeakNetworkOverview', request.serialize)
|
1558
|
+
response = JSON.parse(body)
|
1559
|
+
if response['Response'].key?('Error') == false
|
1560
|
+
model = DescribePeakNetworkOverviewResponse.new
|
1561
|
+
model.deserialize(response['Response'])
|
1562
|
+
model
|
1563
|
+
else
|
1564
|
+
code = response['Response']['Error']['Code']
|
1565
|
+
message = response['Response']['Error']['Message']
|
1566
|
+
reqid = response['Response']['RequestId']
|
1567
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1568
|
+
end
|
1569
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1570
|
+
raise e
|
1571
|
+
rescue StandardError => e
|
1572
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1573
|
+
end
|
1574
|
+
|
1575
|
+
# 查询自定义路由策略与云联网路由策略冲突列表
|
1576
|
+
|
1577
|
+
# @param request: Request instance for DescribeRouteConflicts.
|
1578
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeRouteConflictsRequest`
|
1579
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeRouteConflictsResponse`
|
1580
|
+
def DescribeRouteConflicts(request)
|
1581
|
+
body = send_request('DescribeRouteConflicts', request.serialize)
|
1582
|
+
response = JSON.parse(body)
|
1583
|
+
if response['Response'].key?('Error') == false
|
1584
|
+
model = DescribeRouteConflictsResponse.new
|
1585
|
+
model.deserialize(response['Response'])
|
1586
|
+
model
|
1587
|
+
else
|
1588
|
+
code = response['Response']['Error']['Code']
|
1589
|
+
message = response['Response']['Error']['Message']
|
1590
|
+
reqid = response['Response']['RequestId']
|
1591
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1592
|
+
end
|
1593
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1594
|
+
raise e
|
1595
|
+
rescue StandardError => e
|
1596
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1597
|
+
end
|
1598
|
+
|
1599
|
+
# 查询路由表对象列表
|
1600
|
+
|
1601
|
+
# @param request: Request instance for DescribeRouteTables.
|
1602
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeRouteTablesRequest`
|
1603
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeRouteTablesResponse`
|
1604
|
+
def DescribeRouteTables(request)
|
1605
|
+
body = send_request('DescribeRouteTables', request.serialize)
|
1606
|
+
response = JSON.parse(body)
|
1607
|
+
if response['Response'].key?('Error') == false
|
1608
|
+
model = DescribeRouteTablesResponse.new
|
1609
|
+
model.deserialize(response['Response'])
|
1610
|
+
model
|
1611
|
+
else
|
1612
|
+
code = response['Response']['Error']['Code']
|
1613
|
+
message = response['Response']['Error']['Message']
|
1614
|
+
reqid = response['Response']['RequestId']
|
1615
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1616
|
+
end
|
1617
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1618
|
+
raise e
|
1619
|
+
rescue StandardError => e
|
1620
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1621
|
+
end
|
1622
|
+
|
1623
|
+
# 查询安全组关联实例统计
|
1624
|
+
|
1625
|
+
# @param request: Request instance for DescribeSecurityGroupAssociationStatistics.
|
1626
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupAssociationStatisticsRequest`
|
1627
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupAssociationStatisticsResponse`
|
1628
|
+
def DescribeSecurityGroupAssociationStatistics(request)
|
1629
|
+
body = send_request('DescribeSecurityGroupAssociationStatistics', request.serialize)
|
1630
|
+
response = JSON.parse(body)
|
1631
|
+
if response['Response'].key?('Error') == false
|
1632
|
+
model = DescribeSecurityGroupAssociationStatisticsResponse.new
|
1633
|
+
model.deserialize(response['Response'])
|
1634
|
+
model
|
1635
|
+
else
|
1636
|
+
code = response['Response']['Error']['Code']
|
1637
|
+
message = response['Response']['Error']['Message']
|
1638
|
+
reqid = response['Response']['RequestId']
|
1639
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1640
|
+
end
|
1641
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1642
|
+
raise e
|
1643
|
+
rescue StandardError => e
|
1644
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1645
|
+
end
|
1646
|
+
|
1647
|
+
# 查询用户安全组配额
|
1648
|
+
|
1649
|
+
# @param request: Request instance for DescribeSecurityGroupLimits.
|
1650
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupLimitsRequest`
|
1651
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupLimitsResponse`
|
1652
|
+
def DescribeSecurityGroupLimits(request)
|
1653
|
+
body = send_request('DescribeSecurityGroupLimits', request.serialize)
|
1654
|
+
response = JSON.parse(body)
|
1655
|
+
if response['Response'].key?('Error') == false
|
1656
|
+
model = DescribeSecurityGroupLimitsResponse.new
|
1657
|
+
model.deserialize(response['Response'])
|
1658
|
+
model
|
1659
|
+
else
|
1660
|
+
code = response['Response']['Error']['Code']
|
1661
|
+
message = response['Response']['Error']['Message']
|
1662
|
+
reqid = response['Response']['RequestId']
|
1663
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1664
|
+
end
|
1665
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1666
|
+
raise e
|
1667
|
+
rescue StandardError => e
|
1668
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1669
|
+
end
|
1670
|
+
|
1671
|
+
# 查询安全组规则
|
1672
|
+
|
1673
|
+
# @param request: Request instance for DescribeSecurityGroupPolicies.
|
1674
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupPoliciesRequest`
|
1675
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupPoliciesResponse`
|
1676
|
+
def DescribeSecurityGroupPolicies(request)
|
1677
|
+
body = send_request('DescribeSecurityGroupPolicies', request.serialize)
|
1678
|
+
response = JSON.parse(body)
|
1679
|
+
if response['Response'].key?('Error') == false
|
1680
|
+
model = DescribeSecurityGroupPoliciesResponse.new
|
1681
|
+
model.deserialize(response['Response'])
|
1682
|
+
model
|
1683
|
+
else
|
1684
|
+
code = response['Response']['Error']['Code']
|
1685
|
+
message = response['Response']['Error']['Message']
|
1686
|
+
reqid = response['Response']['RequestId']
|
1687
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1688
|
+
end
|
1689
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1690
|
+
raise e
|
1691
|
+
rescue StandardError => e
|
1692
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1693
|
+
end
|
1694
|
+
|
1695
|
+
# 查看安全组
|
1696
|
+
|
1697
|
+
# @param request: Request instance for DescribeSecurityGroups.
|
1698
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupsRequest`
|
1699
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeSecurityGroupsResponse`
|
1700
|
+
def DescribeSecurityGroups(request)
|
1701
|
+
body = send_request('DescribeSecurityGroups', request.serialize)
|
1702
|
+
response = JSON.parse(body)
|
1703
|
+
if response['Response'].key?('Error') == false
|
1704
|
+
model = DescribeSecurityGroupsResponse.new
|
1705
|
+
model.deserialize(response['Response'])
|
1706
|
+
model
|
1707
|
+
else
|
1708
|
+
code = response['Response']['Error']['Code']
|
1709
|
+
message = response['Response']['Error']['Message']
|
1710
|
+
reqid = response['Response']['RequestId']
|
1711
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1712
|
+
end
|
1713
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1714
|
+
raise e
|
1715
|
+
rescue StandardError => e
|
1716
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1717
|
+
end
|
1718
|
+
|
1719
|
+
# 本接口(DescribeSnapshots)用于查询快照的详细信息。
|
1720
|
+
|
1721
|
+
# * 根据快照ID、创建快照的云硬盘ID、创建快照的云硬盘类型等对结果进行过滤,不同条件之间为与(AND)的关系,过滤信息详细请见过滤器`Filter`。
|
1722
|
+
# * 如果参数为空,返回当前用户一定数量(`Limit`所指定的数量,默认为20)的快照列表。
|
1723
|
+
|
1724
|
+
# @param request: Request instance for DescribeSnapshots.
|
1725
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeSnapshotsRequest`
|
1726
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeSnapshotsResponse`
|
1727
|
+
def DescribeSnapshots(request)
|
1728
|
+
body = send_request('DescribeSnapshots', request.serialize)
|
1729
|
+
response = JSON.parse(body)
|
1730
|
+
if response['Response'].key?('Error') == false
|
1731
|
+
model = DescribeSnapshotsResponse.new
|
1732
|
+
model.deserialize(response['Response'])
|
1733
|
+
model
|
1734
|
+
else
|
1735
|
+
code = response['Response']['Error']['Code']
|
1736
|
+
message = response['Response']['Error']['Message']
|
1737
|
+
reqid = response['Response']['RequestId']
|
1738
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1739
|
+
end
|
1740
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1741
|
+
raise e
|
1742
|
+
rescue StandardError => e
|
1743
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1744
|
+
end
|
1745
|
+
|
1746
|
+
# 查询子网列表
|
1747
|
+
|
1748
|
+
# @param request: Request instance for DescribeSubnets.
|
1749
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeSubnetsRequest`
|
1750
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeSubnetsResponse`
|
1751
|
+
def DescribeSubnets(request)
|
1752
|
+
body = send_request('DescribeSubnets', request.serialize)
|
1753
|
+
response = JSON.parse(body)
|
1754
|
+
if response['Response'].key?('Error') == false
|
1755
|
+
model = DescribeSubnetsResponse.new
|
1756
|
+
model.deserialize(response['Response'])
|
1757
|
+
model
|
1758
|
+
else
|
1759
|
+
code = response['Response']['Error']['Code']
|
1760
|
+
message = response['Response']['Error']['Message']
|
1761
|
+
reqid = response['Response']['RequestId']
|
1762
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1763
|
+
end
|
1764
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1765
|
+
raise e
|
1766
|
+
rescue StandardError => e
|
1767
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1768
|
+
end
|
1769
|
+
|
1770
|
+
# 获取负载均衡后端服务的健康检查状态。
|
1771
|
+
|
1772
|
+
# @param request: Request instance for DescribeTargetHealth.
|
1773
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeTargetHealthRequest`
|
1774
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeTargetHealthResponse`
|
1775
|
+
def DescribeTargetHealth(request)
|
1776
|
+
body = send_request('DescribeTargetHealth', request.serialize)
|
1777
|
+
response = JSON.parse(body)
|
1778
|
+
if response['Response'].key?('Error') == false
|
1779
|
+
model = DescribeTargetHealthResponse.new
|
1780
|
+
model.deserialize(response['Response'])
|
1781
|
+
model
|
1782
|
+
else
|
1783
|
+
code = response['Response']['Error']['Code']
|
1784
|
+
message = response['Response']['Error']['Message']
|
1785
|
+
reqid = response['Response']['RequestId']
|
1786
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1787
|
+
end
|
1788
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1789
|
+
raise e
|
1790
|
+
rescue StandardError => e
|
1791
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1792
|
+
end
|
1793
|
+
|
1794
|
+
# 查询负载均衡绑定的后端服务列表。
|
1795
|
+
|
1796
|
+
# @param request: Request instance for DescribeTargets.
|
1797
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeTargetsRequest`
|
1798
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeTargetsResponse`
|
1799
|
+
def DescribeTargets(request)
|
1800
|
+
body = send_request('DescribeTargets', request.serialize)
|
1801
|
+
response = JSON.parse(body)
|
1802
|
+
if response['Response'].key?('Error') == false
|
1803
|
+
model = DescribeTargetsResponse.new
|
1804
|
+
model.deserialize(response['Response'])
|
1805
|
+
model
|
1806
|
+
else
|
1807
|
+
code = response['Response']['Error']['Code']
|
1808
|
+
message = response['Response']['Error']['Message']
|
1809
|
+
reqid = response['Response']['RequestId']
|
1810
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1811
|
+
end
|
1812
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1813
|
+
raise e
|
1814
|
+
rescue StandardError => e
|
1815
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1816
|
+
end
|
1817
|
+
|
1818
|
+
# 查询EIP异步任务执行结果
|
1819
|
+
|
1820
|
+
# @param request: Request instance for DescribeTaskResult.
|
1821
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeTaskResultRequest`
|
1822
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeTaskResultResponse`
|
1823
|
+
def DescribeTaskResult(request)
|
1824
|
+
body = send_request('DescribeTaskResult', request.serialize)
|
1825
|
+
response = JSON.parse(body)
|
1826
|
+
if response['Response'].key?('Error') == false
|
1827
|
+
model = DescribeTaskResultResponse.new
|
1828
|
+
model.deserialize(response['Response'])
|
1829
|
+
model
|
1830
|
+
else
|
1831
|
+
code = response['Response']['Error']['Code']
|
1832
|
+
message = response['Response']['Error']['Message']
|
1833
|
+
reqid = response['Response']['RequestId']
|
1834
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1835
|
+
end
|
1836
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1837
|
+
raise e
|
1838
|
+
rescue StandardError => e
|
1839
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1840
|
+
end
|
1841
|
+
|
1842
|
+
# 本接口(DescribeTaskStatus)用于获取异步任务状态
|
1843
|
+
|
1844
|
+
# @param request: Request instance for DescribeTaskStatus.
|
1845
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeTaskStatusRequest`
|
1846
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeTaskStatusResponse`
|
1847
|
+
def DescribeTaskStatus(request)
|
1848
|
+
body = send_request('DescribeTaskStatus', request.serialize)
|
1849
|
+
response = JSON.parse(body)
|
1850
|
+
if response['Response'].key?('Error') == false
|
1851
|
+
model = DescribeTaskStatusResponse.new
|
1852
|
+
model.deserialize(response['Response'])
|
1853
|
+
model
|
1854
|
+
else
|
1855
|
+
code = response['Response']['Error']['Code']
|
1856
|
+
message = response['Response']['Error']['Message']
|
1857
|
+
reqid = response['Response']['RequestId']
|
1858
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1859
|
+
end
|
1860
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1861
|
+
raise e
|
1862
|
+
rescue StandardError => e
|
1863
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1864
|
+
end
|
1865
|
+
|
1866
|
+
# 查询私有网络列表
|
1867
|
+
|
1868
|
+
# @param request: Request instance for DescribeVpcs.
|
1869
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DescribeVpcsRequest`
|
1870
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DescribeVpcsResponse`
|
1871
|
+
def DescribeVpcs(request)
|
1872
|
+
body = send_request('DescribeVpcs', request.serialize)
|
1873
|
+
response = JSON.parse(body)
|
1874
|
+
if response['Response'].key?('Error') == false
|
1875
|
+
model = DescribeVpcsResponse.new
|
1876
|
+
model.deserialize(response['Response'])
|
1877
|
+
model
|
1878
|
+
else
|
1879
|
+
code = response['Response']['Error']['Code']
|
1880
|
+
message = response['Response']['Error']['Message']
|
1881
|
+
reqid = response['Response']['RequestId']
|
1882
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1883
|
+
end
|
1884
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1885
|
+
raise e
|
1886
|
+
rescue StandardError => e
|
1887
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1888
|
+
end
|
1889
|
+
|
1890
|
+
# 本接口(DetachDisks)用于卸载云硬盘。
|
1891
|
+
|
1892
|
+
# * 支持批量操作,卸载挂载在同一主机上的多块云盘。如果多块云盘中存在不允许卸载的云盘,则操作不执行,返回特定的错误码。
|
1893
|
+
# * 本接口为异步接口,当请求成功返回时,云盘并未立即从主机卸载,可通过接口[DescribeDisks](/document/product/362/16315)来查询对应云盘的状态,如果云盘的状态由“ATTACHED”变为“UNATTACHED”,则为卸载成功。
|
1894
|
+
|
1895
|
+
# @param request: Request instance for DetachDisks.
|
1896
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DetachDisksRequest`
|
1897
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DetachDisksResponse`
|
1898
|
+
def DetachDisks(request)
|
1899
|
+
body = send_request('DetachDisks', request.serialize)
|
1900
|
+
response = JSON.parse(body)
|
1901
|
+
if response['Response'].key?('Error') == false
|
1902
|
+
model = DetachDisksResponse.new
|
1903
|
+
model.deserialize(response['Response'])
|
1904
|
+
model
|
1905
|
+
else
|
1906
|
+
code = response['Response']['Error']['Code']
|
1907
|
+
message = response['Response']['Error']['Message']
|
1908
|
+
reqid = response['Response']['RequestId']
|
1909
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1910
|
+
end
|
1911
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1912
|
+
raise e
|
1913
|
+
rescue StandardError => e
|
1914
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1915
|
+
end
|
1916
|
+
|
1917
|
+
# 弹性网卡解绑云主机
|
1918
|
+
|
1919
|
+
# @param request: Request instance for DetachNetworkInterface.
|
1920
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DetachNetworkInterfaceRequest`
|
1921
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DetachNetworkInterfaceResponse`
|
1922
|
+
def DetachNetworkInterface(request)
|
1923
|
+
body = send_request('DetachNetworkInterface', request.serialize)
|
1924
|
+
response = JSON.parse(body)
|
1925
|
+
if response['Response'].key?('Error') == false
|
1926
|
+
model = DetachNetworkInterfaceResponse.new
|
1927
|
+
model.deserialize(response['Response'])
|
1928
|
+
model
|
1929
|
+
else
|
1930
|
+
code = response['Response']['Error']['Code']
|
1931
|
+
message = response['Response']['Error']['Message']
|
1932
|
+
reqid = response['Response']['RequestId']
|
1933
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1934
|
+
end
|
1935
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1936
|
+
raise e
|
1937
|
+
rescue StandardError => e
|
1938
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1939
|
+
end
|
1940
|
+
|
1941
|
+
# 禁用已启用的子网路由
|
1942
|
+
|
1943
|
+
# @param request: Request instance for DisableRoutes.
|
1944
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DisableRoutesRequest`
|
1945
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DisableRoutesResponse`
|
1946
|
+
def DisableRoutes(request)
|
1947
|
+
body = send_request('DisableRoutes', request.serialize)
|
1948
|
+
response = JSON.parse(body)
|
1949
|
+
if response['Response'].key?('Error') == false
|
1950
|
+
model = DisableRoutesResponse.new
|
1951
|
+
model.deserialize(response['Response'])
|
1952
|
+
model
|
1953
|
+
else
|
1954
|
+
code = response['Response']['Error']['Code']
|
1955
|
+
message = response['Response']['Error']['Message']
|
1956
|
+
reqid = response['Response']['RequestId']
|
1957
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1958
|
+
end
|
1959
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1960
|
+
raise e
|
1961
|
+
rescue StandardError => e
|
1962
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1963
|
+
end
|
1964
|
+
|
1965
|
+
# 解绑弹性公网IP(简称 EIP)
|
1966
|
+
# 只有状态为 BIND 和 BIND_ENI 的 EIP 才能进行解绑定操作。
|
1967
|
+
# EIP 如果被封堵,则不能进行解绑定操作。
|
1968
|
+
|
1969
|
+
# @param request: Request instance for DisassociateAddress.
|
1970
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DisassociateAddressRequest`
|
1971
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DisassociateAddressResponse`
|
1972
|
+
def DisassociateAddress(request)
|
1973
|
+
body = send_request('DisassociateAddress', request.serialize)
|
1974
|
+
response = JSON.parse(body)
|
1975
|
+
if response['Response'].key?('Error') == false
|
1976
|
+
model = DisassociateAddressResponse.new
|
1977
|
+
model.deserialize(response['Response'])
|
1978
|
+
model
|
1979
|
+
else
|
1980
|
+
code = response['Response']['Error']['Code']
|
1981
|
+
message = response['Response']['Error']['Message']
|
1982
|
+
reqid = response['Response']['RequestId']
|
1983
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
1984
|
+
end
|
1985
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
1986
|
+
raise e
|
1987
|
+
rescue StandardError => e
|
1988
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
1989
|
+
end
|
1990
|
+
|
1991
|
+
# 用于解除实例的密钥绑定关系。
|
1992
|
+
|
1993
|
+
# @param request: Request instance for DisassociateInstancesKeyPairs.
|
1994
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DisassociateInstancesKeyPairsRequest`
|
1995
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DisassociateInstancesKeyPairsResponse`
|
1996
|
+
def DisassociateInstancesKeyPairs(request)
|
1997
|
+
body = send_request('DisassociateInstancesKeyPairs', request.serialize)
|
1998
|
+
response = JSON.parse(body)
|
1999
|
+
if response['Response'].key?('Error') == false
|
2000
|
+
model = DisassociateInstancesKeyPairsResponse.new
|
2001
|
+
model.deserialize(response['Response'])
|
2002
|
+
model
|
2003
|
+
else
|
2004
|
+
code = response['Response']['Error']['Code']
|
2005
|
+
message = response['Response']['Error']['Message']
|
2006
|
+
reqid = response['Response']['RequestId']
|
2007
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2008
|
+
end
|
2009
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2010
|
+
raise e
|
2011
|
+
rescue StandardError => e
|
2012
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2013
|
+
end
|
2014
|
+
|
2015
|
+
# 解绑安全组
|
2016
|
+
|
2017
|
+
# @param request: Request instance for DisassociateSecurityGroups.
|
2018
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::DisassociateSecurityGroupsRequest`
|
2019
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::DisassociateSecurityGroupsResponse`
|
2020
|
+
def DisassociateSecurityGroups(request)
|
2021
|
+
body = send_request('DisassociateSecurityGroups', request.serialize)
|
2022
|
+
response = JSON.parse(body)
|
2023
|
+
if response['Response'].key?('Error') == false
|
2024
|
+
model = DisassociateSecurityGroupsResponse.new
|
2025
|
+
model.deserialize(response['Response'])
|
2026
|
+
model
|
2027
|
+
else
|
2028
|
+
code = response['Response']['Error']['Code']
|
2029
|
+
message = response['Response']['Error']['Message']
|
2030
|
+
reqid = response['Response']['RequestId']
|
2031
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2032
|
+
end
|
2033
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2034
|
+
raise e
|
2035
|
+
rescue StandardError => e
|
2036
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2037
|
+
end
|
2038
|
+
|
2039
|
+
# 启用已禁用的子网路由。
|
2040
|
+
# 本接口会校验启用后,是否与已有路由冲突,如果冲突,则无法启用,失败处理。路由冲突时,需要先禁用与之冲突的路由,才能启用该路由。
|
2041
|
+
|
2042
|
+
# @param request: Request instance for EnableRoutes.
|
2043
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::EnableRoutesRequest`
|
2044
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::EnableRoutesResponse`
|
2045
|
+
def EnableRoutes(request)
|
2046
|
+
body = send_request('EnableRoutes', request.serialize)
|
2047
|
+
response = JSON.parse(body)
|
2048
|
+
if response['Response'].key?('Error') == false
|
2049
|
+
model = EnableRoutesResponse.new
|
2050
|
+
model.deserialize(response['Response'])
|
2051
|
+
model
|
2052
|
+
else
|
2053
|
+
code = response['Response']['Error']['Code']
|
2054
|
+
message = response['Response']['Error']['Message']
|
2055
|
+
reqid = response['Response']['RequestId']
|
2056
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2057
|
+
end
|
2058
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2059
|
+
raise e
|
2060
|
+
rescue StandardError => e
|
2061
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2062
|
+
end
|
2063
|
+
|
2064
|
+
# 导入自定义镜像,支持 RAW、VHD、QCOW2、VMDK 镜像格式
|
2065
|
+
|
2066
|
+
# @param request: Request instance for ImportCustomImage.
|
2067
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ImportCustomImageRequest`
|
2068
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ImportCustomImageResponse`
|
2069
|
+
def ImportCustomImage(request)
|
2070
|
+
body = send_request('ImportCustomImage', request.serialize)
|
2071
|
+
response = JSON.parse(body)
|
2072
|
+
if response['Response'].key?('Error') == false
|
2073
|
+
model = ImportCustomImageResponse.new
|
2074
|
+
model.deserialize(response['Response'])
|
2075
|
+
model
|
2076
|
+
else
|
2077
|
+
code = response['Response']['Error']['Code']
|
2078
|
+
message = response['Response']['Error']['Message']
|
2079
|
+
reqid = response['Response']['RequestId']
|
2080
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2081
|
+
end
|
2082
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2083
|
+
raise e
|
2084
|
+
rescue StandardError => e
|
2085
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2086
|
+
end
|
2087
|
+
|
2088
|
+
# 从CVM产品导入镜像到ECM
|
2089
|
+
|
2090
|
+
# @param request: Request instance for ImportImage.
|
2091
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ImportImageRequest`
|
2092
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ImportImageResponse`
|
2093
|
+
def ImportImage(request)
|
2094
|
+
body = send_request('ImportImage', request.serialize)
|
2095
|
+
response = JSON.parse(body)
|
2096
|
+
if response['Response'].key?('Error') == false
|
2097
|
+
model = ImportImageResponse.new
|
2098
|
+
model.deserialize(response['Response'])
|
2099
|
+
model
|
2100
|
+
else
|
2101
|
+
code = response['Response']['Error']['Code']
|
2102
|
+
message = response['Response']['Error']['Message']
|
2103
|
+
reqid = response['Response']['RequestId']
|
2104
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2105
|
+
end
|
2106
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2107
|
+
raise e
|
2108
|
+
rescue StandardError => e
|
2109
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2110
|
+
end
|
2111
|
+
|
2112
|
+
# 弹性网卡迁移
|
2113
|
+
|
2114
|
+
# @param request: Request instance for MigrateNetworkInterface.
|
2115
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::MigrateNetworkInterfaceRequest`
|
2116
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::MigrateNetworkInterfaceResponse`
|
2117
|
+
def MigrateNetworkInterface(request)
|
2118
|
+
body = send_request('MigrateNetworkInterface', request.serialize)
|
2119
|
+
response = JSON.parse(body)
|
2120
|
+
if response['Response'].key?('Error') == false
|
2121
|
+
model = MigrateNetworkInterfaceResponse.new
|
2122
|
+
model.deserialize(response['Response'])
|
2123
|
+
model
|
2124
|
+
else
|
2125
|
+
code = response['Response']['Error']['Code']
|
2126
|
+
message = response['Response']['Error']['Message']
|
2127
|
+
reqid = response['Response']['RequestId']
|
2128
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2129
|
+
end
|
2130
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2131
|
+
raise e
|
2132
|
+
rescue StandardError => e
|
2133
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2134
|
+
end
|
2135
|
+
|
2136
|
+
# 弹性网卡内网IP迁移。
|
2137
|
+
# 该接口用于将一个内网IP从一个弹性网卡上迁移到另外一个弹性网卡,主IP地址不支持迁移。
|
2138
|
+
# 迁移前后的弹性网卡必须在同一个子网内。
|
2139
|
+
|
2140
|
+
# @param request: Request instance for MigratePrivateIpAddress.
|
2141
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::MigratePrivateIpAddressRequest`
|
2142
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::MigratePrivateIpAddressResponse`
|
2143
|
+
def MigratePrivateIpAddress(request)
|
2144
|
+
body = send_request('MigratePrivateIpAddress', request.serialize)
|
2145
|
+
response = JSON.parse(body)
|
2146
|
+
if response['Response'].key?('Error') == false
|
2147
|
+
model = MigratePrivateIpAddressResponse.new
|
2148
|
+
model.deserialize(response['Response'])
|
2149
|
+
model
|
2150
|
+
else
|
2151
|
+
code = response['Response']['Error']['Code']
|
2152
|
+
message = response['Response']['Error']['Message']
|
2153
|
+
reqid = response['Response']['RequestId']
|
2154
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2155
|
+
end
|
2156
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2157
|
+
raise e
|
2158
|
+
rescue StandardError => e
|
2159
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2160
|
+
end
|
2161
|
+
|
2162
|
+
# 修改弹性公网IP属性
|
2163
|
+
|
2164
|
+
# @param request: Request instance for ModifyAddressAttribute.
|
2165
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyAddressAttributeRequest`
|
2166
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyAddressAttributeResponse`
|
2167
|
+
def ModifyAddressAttribute(request)
|
2168
|
+
body = send_request('ModifyAddressAttribute', request.serialize)
|
2169
|
+
response = JSON.parse(body)
|
2170
|
+
if response['Response'].key?('Error') == false
|
2171
|
+
model = ModifyAddressAttributeResponse.new
|
2172
|
+
model.deserialize(response['Response'])
|
2173
|
+
model
|
2174
|
+
else
|
2175
|
+
code = response['Response']['Error']['Code']
|
2176
|
+
message = response['Response']['Error']['Message']
|
2177
|
+
reqid = response['Response']['RequestId']
|
2178
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2179
|
+
end
|
2180
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2181
|
+
raise e
|
2182
|
+
rescue StandardError => e
|
2183
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2184
|
+
end
|
2185
|
+
|
2186
|
+
# 调整弹性公网IP带宽
|
2187
|
+
|
2188
|
+
# @param request: Request instance for ModifyAddressesBandwidth.
|
2189
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyAddressesBandwidthRequest`
|
2190
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyAddressesBandwidthResponse`
|
2191
|
+
def ModifyAddressesBandwidth(request)
|
2192
|
+
body = send_request('ModifyAddressesBandwidth', request.serialize)
|
2193
|
+
response = JSON.parse(body)
|
2194
|
+
if response['Response'].key?('Error') == false
|
2195
|
+
model = ModifyAddressesBandwidthResponse.new
|
2196
|
+
model.deserialize(response['Response'])
|
2197
|
+
model
|
2198
|
+
else
|
2199
|
+
code = response['Response']['Error']['Code']
|
2200
|
+
message = response['Response']['Error']['Message']
|
2201
|
+
reqid = response['Response']['RequestId']
|
2202
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2203
|
+
end
|
2204
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2205
|
+
raise e
|
2206
|
+
rescue StandardError => e
|
2207
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2208
|
+
end
|
2209
|
+
|
2210
|
+
# 修改在一个可用区下创建实例时使用的默认子网(创建实例时,未填写VPC参数时使用的sunbetId)
|
2211
|
+
|
2212
|
+
# @param request: Request instance for ModifyDefaultSubnet.
|
2213
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyDefaultSubnetRequest`
|
2214
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyDefaultSubnetResponse`
|
2215
|
+
def ModifyDefaultSubnet(request)
|
2216
|
+
body = send_request('ModifyDefaultSubnet', request.serialize)
|
2217
|
+
response = JSON.parse(body)
|
2218
|
+
if response['Response'].key?('Error') == false
|
2219
|
+
model = ModifyDefaultSubnetResponse.new
|
2220
|
+
model.deserialize(response['Response'])
|
2221
|
+
model
|
2222
|
+
else
|
2223
|
+
code = response['Response']['Error']['Code']
|
2224
|
+
message = response['Response']['Error']['Message']
|
2225
|
+
reqid = response['Response']['RequestId']
|
2226
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2227
|
+
end
|
2228
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2229
|
+
raise e
|
2230
|
+
rescue StandardError => e
|
2231
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2232
|
+
end
|
2233
|
+
|
2234
|
+
# 用于修改高可用虚拟IP(HAVIP)属性
|
2235
|
+
|
2236
|
+
# @param request: Request instance for ModifyHaVipAttribute.
|
2237
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyHaVipAttributeRequest`
|
2238
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyHaVipAttributeResponse`
|
2239
|
+
def ModifyHaVipAttribute(request)
|
2240
|
+
body = send_request('ModifyHaVipAttribute', request.serialize)
|
2241
|
+
response = JSON.parse(body)
|
2242
|
+
if response['Response'].key?('Error') == false
|
2243
|
+
model = ModifyHaVipAttributeResponse.new
|
2244
|
+
model.deserialize(response['Response'])
|
2245
|
+
model
|
2246
|
+
else
|
2247
|
+
code = response['Response']['Error']['Code']
|
2248
|
+
message = response['Response']['Error']['Message']
|
2249
|
+
reqid = response['Response']['RequestId']
|
2250
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2251
|
+
end
|
2252
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2253
|
+
raise e
|
2254
|
+
rescue StandardError => e
|
2255
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2256
|
+
end
|
2257
|
+
|
2258
|
+
# 本接口(ModifyImageAttribute)用于修改镜像属性。
|
2259
|
+
|
2260
|
+
# @param request: Request instance for ModifyImageAttribute.
|
2261
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyImageAttributeRequest`
|
2262
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyImageAttributeResponse`
|
2263
|
+
def ModifyImageAttribute(request)
|
2264
|
+
body = send_request('ModifyImageAttribute', request.serialize)
|
2265
|
+
response = JSON.parse(body)
|
2266
|
+
if response['Response'].key?('Error') == false
|
2267
|
+
model = ModifyImageAttributeResponse.new
|
2268
|
+
model.deserialize(response['Response'])
|
2269
|
+
model
|
2270
|
+
else
|
2271
|
+
code = response['Response']['Error']['Code']
|
2272
|
+
message = response['Response']['Error']['Message']
|
2273
|
+
reqid = response['Response']['RequestId']
|
2274
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2275
|
+
end
|
2276
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2277
|
+
raise e
|
2278
|
+
rescue StandardError => e
|
2279
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2280
|
+
end
|
2281
|
+
|
2282
|
+
# 修改实例的属性。
|
2283
|
+
|
2284
|
+
# @param request: Request instance for ModifyInstancesAttribute.
|
2285
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyInstancesAttributeRequest`
|
2286
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyInstancesAttributeResponse`
|
2287
|
+
def ModifyInstancesAttribute(request)
|
2288
|
+
body = send_request('ModifyInstancesAttribute', request.serialize)
|
2289
|
+
response = JSON.parse(body)
|
2290
|
+
if response['Response'].key?('Error') == false
|
2291
|
+
model = ModifyInstancesAttributeResponse.new
|
2292
|
+
model.deserialize(response['Response'])
|
2293
|
+
model
|
2294
|
+
else
|
2295
|
+
code = response['Response']['Error']['Code']
|
2296
|
+
message = response['Response']['Error']['Message']
|
2297
|
+
reqid = response['Response']['RequestId']
|
2298
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2299
|
+
end
|
2300
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2301
|
+
raise e
|
2302
|
+
rescue StandardError => e
|
2303
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2304
|
+
end
|
2305
|
+
|
2306
|
+
# 本接口(ModifyIpv6AddressesAttribute)用于修改弹性网卡IPv6地址属性。
|
2307
|
+
|
2308
|
+
# @param request: Request instance for ModifyIpv6AddressesAttribute.
|
2309
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyIpv6AddressesAttributeRequest`
|
2310
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyIpv6AddressesAttributeResponse`
|
2311
|
+
def ModifyIpv6AddressesAttribute(request)
|
2312
|
+
body = send_request('ModifyIpv6AddressesAttribute', request.serialize)
|
2313
|
+
response = JSON.parse(body)
|
2314
|
+
if response['Response'].key?('Error') == false
|
2315
|
+
model = ModifyIpv6AddressesAttributeResponse.new
|
2316
|
+
model.deserialize(response['Response'])
|
2317
|
+
model
|
2318
|
+
else
|
2319
|
+
code = response['Response']['Error']['Code']
|
2320
|
+
message = response['Response']['Error']['Message']
|
2321
|
+
reqid = response['Response']['RequestId']
|
2322
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2323
|
+
end
|
2324
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2325
|
+
raise e
|
2326
|
+
rescue StandardError => e
|
2327
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2328
|
+
end
|
2329
|
+
|
2330
|
+
# 修改负载均衡监听器属性。
|
2331
|
+
|
2332
|
+
# @param request: Request instance for ModifyListener.
|
2333
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyListenerRequest`
|
2334
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyListenerResponse`
|
2335
|
+
def ModifyListener(request)
|
2336
|
+
body = send_request('ModifyListener', request.serialize)
|
2337
|
+
response = JSON.parse(body)
|
2338
|
+
if response['Response'].key?('Error') == false
|
2339
|
+
model = ModifyListenerResponse.new
|
2340
|
+
model.deserialize(response['Response'])
|
2341
|
+
model
|
2342
|
+
else
|
2343
|
+
code = response['Response']['Error']['Code']
|
2344
|
+
message = response['Response']['Error']['Message']
|
2345
|
+
reqid = response['Response']['RequestId']
|
2346
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2347
|
+
end
|
2348
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2349
|
+
raise e
|
2350
|
+
rescue StandardError => e
|
2351
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2352
|
+
end
|
2353
|
+
|
2354
|
+
# 修改负载均衡实例的属性。
|
2355
|
+
|
2356
|
+
# @param request: Request instance for ModifyLoadBalancerAttributes.
|
2357
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyLoadBalancerAttributesRequest`
|
2358
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyLoadBalancerAttributesResponse`
|
2359
|
+
def ModifyLoadBalancerAttributes(request)
|
2360
|
+
body = send_request('ModifyLoadBalancerAttributes', request.serialize)
|
2361
|
+
response = JSON.parse(body)
|
2362
|
+
if response['Response'].key?('Error') == false
|
2363
|
+
model = ModifyLoadBalancerAttributesResponse.new
|
2364
|
+
model.deserialize(response['Response'])
|
2365
|
+
model
|
2366
|
+
else
|
2367
|
+
code = response['Response']['Error']['Code']
|
2368
|
+
message = response['Response']['Error']['Message']
|
2369
|
+
reqid = response['Response']['RequestId']
|
2370
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2371
|
+
end
|
2372
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2373
|
+
raise e
|
2374
|
+
rescue StandardError => e
|
2375
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2376
|
+
end
|
2377
|
+
|
2378
|
+
# 修改模块配置,已关联实例的模块不支持调整配置。
|
2379
|
+
|
2380
|
+
# @param request: Request instance for ModifyModuleConfig.
|
2381
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyModuleConfigRequest`
|
2382
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyModuleConfigResponse`
|
2383
|
+
def ModifyModuleConfig(request)
|
2384
|
+
body = send_request('ModifyModuleConfig', request.serialize)
|
2385
|
+
response = JSON.parse(body)
|
2386
|
+
if response['Response'].key?('Error') == false
|
2387
|
+
model = ModifyModuleConfigResponse.new
|
2388
|
+
model.deserialize(response['Response'])
|
2389
|
+
model
|
2390
|
+
else
|
2391
|
+
code = response['Response']['Error']['Code']
|
2392
|
+
message = response['Response']['Error']['Message']
|
2393
|
+
reqid = response['Response']['RequestId']
|
2394
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2395
|
+
end
|
2396
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2397
|
+
raise e
|
2398
|
+
rescue StandardError => e
|
2399
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2400
|
+
end
|
2401
|
+
|
2402
|
+
# 修改模块是否禁止分配外网ip的属性。
|
2403
|
+
|
2404
|
+
# @param request: Request instance for ModifyModuleDisableWanIp.
|
2405
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyModuleDisableWanIpRequest`
|
2406
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyModuleDisableWanIpResponse`
|
2407
|
+
def ModifyModuleDisableWanIp(request)
|
2408
|
+
body = send_request('ModifyModuleDisableWanIp', request.serialize)
|
2409
|
+
response = JSON.parse(body)
|
2410
|
+
if response['Response'].key?('Error') == false
|
2411
|
+
model = ModifyModuleDisableWanIpResponse.new
|
2412
|
+
model.deserialize(response['Response'])
|
2413
|
+
model
|
2414
|
+
else
|
2415
|
+
code = response['Response']['Error']['Code']
|
2416
|
+
message = response['Response']['Error']['Message']
|
2417
|
+
reqid = response['Response']['RequestId']
|
2418
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2419
|
+
end
|
2420
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2421
|
+
raise e
|
2422
|
+
rescue StandardError => e
|
2423
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2424
|
+
end
|
2425
|
+
|
2426
|
+
# 修改模块的默认镜像
|
2427
|
+
|
2428
|
+
# @param request: Request instance for ModifyModuleImage.
|
2429
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyModuleImageRequest`
|
2430
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyModuleImageResponse`
|
2431
|
+
def ModifyModuleImage(request)
|
2432
|
+
body = send_request('ModifyModuleImage', request.serialize)
|
2433
|
+
response = JSON.parse(body)
|
2434
|
+
if response['Response'].key?('Error') == false
|
2435
|
+
model = ModifyModuleImageResponse.new
|
2436
|
+
model.deserialize(response['Response'])
|
2437
|
+
model
|
2438
|
+
else
|
2439
|
+
code = response['Response']['Error']['Code']
|
2440
|
+
message = response['Response']['Error']['Message']
|
2441
|
+
reqid = response['Response']['RequestId']
|
2442
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2443
|
+
end
|
2444
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2445
|
+
raise e
|
2446
|
+
rescue StandardError => e
|
2447
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2448
|
+
end
|
2449
|
+
|
2450
|
+
# 修改模块IP直通。
|
2451
|
+
|
2452
|
+
# @param request: Request instance for ModifyModuleIpDirect.
|
2453
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyModuleIpDirectRequest`
|
2454
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyModuleIpDirectResponse`
|
2455
|
+
def ModifyModuleIpDirect(request)
|
2456
|
+
body = send_request('ModifyModuleIpDirect', request.serialize)
|
2457
|
+
response = JSON.parse(body)
|
2458
|
+
if response['Response'].key?('Error') == false
|
2459
|
+
model = ModifyModuleIpDirectResponse.new
|
2460
|
+
model.deserialize(response['Response'])
|
2461
|
+
model
|
2462
|
+
else
|
2463
|
+
code = response['Response']['Error']['Code']
|
2464
|
+
message = response['Response']['Error']['Message']
|
2465
|
+
reqid = response['Response']['RequestId']
|
2466
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2467
|
+
end
|
2468
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2469
|
+
raise e
|
2470
|
+
rescue StandardError => e
|
2471
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2472
|
+
end
|
2473
|
+
|
2474
|
+
# 修改模块名称
|
2475
|
+
|
2476
|
+
# @param request: Request instance for ModifyModuleName.
|
2477
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyModuleNameRequest`
|
2478
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyModuleNameResponse`
|
2479
|
+
def ModifyModuleName(request)
|
2480
|
+
body = send_request('ModifyModuleName', request.serialize)
|
2481
|
+
response = JSON.parse(body)
|
2482
|
+
if response['Response'].key?('Error') == false
|
2483
|
+
model = ModifyModuleNameResponse.new
|
2484
|
+
model.deserialize(response['Response'])
|
2485
|
+
model
|
2486
|
+
else
|
2487
|
+
code = response['Response']['Error']['Code']
|
2488
|
+
message = response['Response']['Error']['Message']
|
2489
|
+
reqid = response['Response']['RequestId']
|
2490
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2491
|
+
end
|
2492
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2493
|
+
raise e
|
2494
|
+
rescue StandardError => e
|
2495
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2496
|
+
end
|
2497
|
+
|
2498
|
+
# 修改模块默认带宽上限
|
2499
|
+
|
2500
|
+
# @param request: Request instance for ModifyModuleNetwork.
|
2501
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyModuleNetworkRequest`
|
2502
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyModuleNetworkResponse`
|
2503
|
+
def ModifyModuleNetwork(request)
|
2504
|
+
body = send_request('ModifyModuleNetwork', request.serialize)
|
2505
|
+
response = JSON.parse(body)
|
2506
|
+
if response['Response'].key?('Error') == false
|
2507
|
+
model = ModifyModuleNetworkResponse.new
|
2508
|
+
model.deserialize(response['Response'])
|
2509
|
+
model
|
2510
|
+
else
|
2511
|
+
code = response['Response']['Error']['Code']
|
2512
|
+
message = response['Response']['Error']['Message']
|
2513
|
+
reqid = response['Response']['RequestId']
|
2514
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2515
|
+
end
|
2516
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2517
|
+
raise e
|
2518
|
+
rescue StandardError => e
|
2519
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2520
|
+
end
|
2521
|
+
|
2522
|
+
# 修改模块默认安全组
|
2523
|
+
|
2524
|
+
# @param request: Request instance for ModifyModuleSecurityGroups.
|
2525
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyModuleSecurityGroupsRequest`
|
2526
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyModuleSecurityGroupsResponse`
|
2527
|
+
def ModifyModuleSecurityGroups(request)
|
2528
|
+
body = send_request('ModifyModuleSecurityGroups', request.serialize)
|
2529
|
+
response = JSON.parse(body)
|
2530
|
+
if response['Response'].key?('Error') == false
|
2531
|
+
model = ModifyModuleSecurityGroupsResponse.new
|
2532
|
+
model.deserialize(response['Response'])
|
2533
|
+
model
|
2534
|
+
else
|
2535
|
+
code = response['Response']['Error']['Code']
|
2536
|
+
message = response['Response']['Error']['Message']
|
2537
|
+
reqid = response['Response']['RequestId']
|
2538
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2539
|
+
end
|
2540
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2541
|
+
raise e
|
2542
|
+
rescue StandardError => e
|
2543
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2544
|
+
end
|
2545
|
+
|
2546
|
+
# 用于修改弹性网卡内网IP属性。
|
2547
|
+
|
2548
|
+
# @param request: Request instance for ModifyPrivateIpAddressesAttribute.
|
2549
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyPrivateIpAddressesAttributeRequest`
|
2550
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyPrivateIpAddressesAttributeResponse`
|
2551
|
+
def ModifyPrivateIpAddressesAttribute(request)
|
2552
|
+
body = send_request('ModifyPrivateIpAddressesAttribute', request.serialize)
|
2553
|
+
response = JSON.parse(body)
|
2554
|
+
if response['Response'].key?('Error') == false
|
2555
|
+
model = ModifyPrivateIpAddressesAttributeResponse.new
|
2556
|
+
model.deserialize(response['Response'])
|
2557
|
+
model
|
2558
|
+
else
|
2559
|
+
code = response['Response']['Error']['Code']
|
2560
|
+
message = response['Response']['Error']['Message']
|
2561
|
+
reqid = response['Response']['RequestId']
|
2562
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2563
|
+
end
|
2564
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2565
|
+
raise e
|
2566
|
+
rescue StandardError => e
|
2567
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2568
|
+
end
|
2569
|
+
|
2570
|
+
# 修改路由表属性
|
2571
|
+
|
2572
|
+
# @param request: Request instance for ModifyRouteTableAttribute.
|
2573
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyRouteTableAttributeRequest`
|
2574
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyRouteTableAttributeResponse`
|
2575
|
+
def ModifyRouteTableAttribute(request)
|
2576
|
+
body = send_request('ModifyRouteTableAttribute', request.serialize)
|
2577
|
+
response = JSON.parse(body)
|
2578
|
+
if response['Response'].key?('Error') == false
|
2579
|
+
model = ModifyRouteTableAttributeResponse.new
|
2580
|
+
model.deserialize(response['Response'])
|
2581
|
+
model
|
2582
|
+
else
|
2583
|
+
code = response['Response']['Error']['Code']
|
2584
|
+
message = response['Response']['Error']['Message']
|
2585
|
+
reqid = response['Response']['RequestId']
|
2586
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2587
|
+
end
|
2588
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2589
|
+
raise e
|
2590
|
+
rescue StandardError => e
|
2591
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2592
|
+
end
|
2593
|
+
|
2594
|
+
# 修改安全组属性
|
2595
|
+
|
2596
|
+
# @param request: Request instance for ModifySecurityGroupAttribute.
|
2597
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifySecurityGroupAttributeRequest`
|
2598
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifySecurityGroupAttributeResponse`
|
2599
|
+
def ModifySecurityGroupAttribute(request)
|
2600
|
+
body = send_request('ModifySecurityGroupAttribute', request.serialize)
|
2601
|
+
response = JSON.parse(body)
|
2602
|
+
if response['Response'].key?('Error') == false
|
2603
|
+
model = ModifySecurityGroupAttributeResponse.new
|
2604
|
+
model.deserialize(response['Response'])
|
2605
|
+
model
|
2606
|
+
else
|
2607
|
+
code = response['Response']['Error']['Code']
|
2608
|
+
message = response['Response']['Error']['Message']
|
2609
|
+
reqid = response['Response']['RequestId']
|
2610
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2611
|
+
end
|
2612
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2613
|
+
raise e
|
2614
|
+
rescue StandardError => e
|
2615
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2616
|
+
end
|
2617
|
+
|
2618
|
+
# 修改安全组出站和入站规则
|
2619
|
+
|
2620
|
+
# @param request: Request instance for ModifySecurityGroupPolicies.
|
2621
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifySecurityGroupPoliciesRequest`
|
2622
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifySecurityGroupPoliciesResponse`
|
2623
|
+
def ModifySecurityGroupPolicies(request)
|
2624
|
+
body = send_request('ModifySecurityGroupPolicies', request.serialize)
|
2625
|
+
response = JSON.parse(body)
|
2626
|
+
if response['Response'].key?('Error') == false
|
2627
|
+
model = ModifySecurityGroupPoliciesResponse.new
|
2628
|
+
model.deserialize(response['Response'])
|
2629
|
+
model
|
2630
|
+
else
|
2631
|
+
code = response['Response']['Error']['Code']
|
2632
|
+
message = response['Response']['Error']['Message']
|
2633
|
+
reqid = response['Response']['RequestId']
|
2634
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2635
|
+
end
|
2636
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2637
|
+
raise e
|
2638
|
+
rescue StandardError => e
|
2639
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2640
|
+
end
|
2641
|
+
|
2642
|
+
# 修改子网属性
|
2643
|
+
|
2644
|
+
# @param request: Request instance for ModifySubnetAttribute.
|
2645
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifySubnetAttributeRequest`
|
2646
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifySubnetAttributeResponse`
|
2647
|
+
def ModifySubnetAttribute(request)
|
2648
|
+
body = send_request('ModifySubnetAttribute', request.serialize)
|
2649
|
+
response = JSON.parse(body)
|
2650
|
+
if response['Response'].key?('Error') == false
|
2651
|
+
model = ModifySubnetAttributeResponse.new
|
2652
|
+
model.deserialize(response['Response'])
|
2653
|
+
model
|
2654
|
+
else
|
2655
|
+
code = response['Response']['Error']['Code']
|
2656
|
+
message = response['Response']['Error']['Message']
|
2657
|
+
reqid = response['Response']['RequestId']
|
2658
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2659
|
+
end
|
2660
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2661
|
+
raise e
|
2662
|
+
rescue StandardError => e
|
2663
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2664
|
+
end
|
2665
|
+
|
2666
|
+
# 修改监听器绑定的后端机器的端口。
|
2667
|
+
|
2668
|
+
# @param request: Request instance for ModifyTargetPort.
|
2669
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyTargetPortRequest`
|
2670
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyTargetPortResponse`
|
2671
|
+
def ModifyTargetPort(request)
|
2672
|
+
body = send_request('ModifyTargetPort', request.serialize)
|
2673
|
+
response = JSON.parse(body)
|
2674
|
+
if response['Response'].key?('Error') == false
|
2675
|
+
model = ModifyTargetPortResponse.new
|
2676
|
+
model.deserialize(response['Response'])
|
2677
|
+
model
|
2678
|
+
else
|
2679
|
+
code = response['Response']['Error']['Code']
|
2680
|
+
message = response['Response']['Error']['Message']
|
2681
|
+
reqid = response['Response']['RequestId']
|
2682
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2683
|
+
end
|
2684
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2685
|
+
raise e
|
2686
|
+
rescue StandardError => e
|
2687
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2688
|
+
end
|
2689
|
+
|
2690
|
+
# 修改监听器绑定的后端机器的转发权重。
|
2691
|
+
|
2692
|
+
# @param request: Request instance for ModifyTargetWeight.
|
2693
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyTargetWeightRequest`
|
2694
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyTargetWeightResponse`
|
2695
|
+
def ModifyTargetWeight(request)
|
2696
|
+
body = send_request('ModifyTargetWeight', request.serialize)
|
2697
|
+
response = JSON.parse(body)
|
2698
|
+
if response['Response'].key?('Error') == false
|
2699
|
+
model = ModifyTargetWeightResponse.new
|
2700
|
+
model.deserialize(response['Response'])
|
2701
|
+
model
|
2702
|
+
else
|
2703
|
+
code = response['Response']['Error']['Code']
|
2704
|
+
message = response['Response']['Error']['Message']
|
2705
|
+
reqid = response['Response']['RequestId']
|
2706
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2707
|
+
end
|
2708
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2709
|
+
raise e
|
2710
|
+
rescue StandardError => e
|
2711
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2712
|
+
end
|
2713
|
+
|
2714
|
+
# 修改私有网络(VPC)的相关属性
|
2715
|
+
|
2716
|
+
# @param request: Request instance for ModifyVpcAttribute.
|
2717
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ModifyVpcAttributeRequest`
|
2718
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ModifyVpcAttributeResponse`
|
2719
|
+
def ModifyVpcAttribute(request)
|
2720
|
+
body = send_request('ModifyVpcAttribute', request.serialize)
|
2721
|
+
response = JSON.parse(body)
|
2722
|
+
if response['Response'].key?('Error') == false
|
2723
|
+
model = ModifyVpcAttributeResponse.new
|
2724
|
+
model.deserialize(response['Response'])
|
2725
|
+
model
|
2726
|
+
else
|
2727
|
+
code = response['Response']['Error']['Code']
|
2728
|
+
message = response['Response']['Error']['Message']
|
2729
|
+
reqid = response['Response']['RequestId']
|
2730
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2731
|
+
end
|
2732
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2733
|
+
raise e
|
2734
|
+
rescue StandardError => e
|
2735
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2736
|
+
end
|
2737
|
+
|
2738
|
+
# 只有状态为RUNNING的实例才可以进行此操作;接口调用成功时,实例会进入REBOOTING状态;重启实例成功时,实例会进入RUNNING状态;支持强制重启,强制重启的效果等同于关闭物理计算机的电源开关再重新启动。强制重启可能会导致数据丢失或文件系统损坏,请仅在服务器不能正常重启时使用。
|
2739
|
+
|
2740
|
+
# @param request: Request instance for RebootInstances.
|
2741
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::RebootInstancesRequest`
|
2742
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::RebootInstancesResponse`
|
2743
|
+
def RebootInstances(request)
|
2744
|
+
body = send_request('RebootInstances', request.serialize)
|
2745
|
+
response = JSON.parse(body)
|
2746
|
+
if response['Response'].key?('Error') == false
|
2747
|
+
model = RebootInstancesResponse.new
|
2748
|
+
model.deserialize(response['Response'])
|
2749
|
+
model
|
2750
|
+
else
|
2751
|
+
code = response['Response']['Error']['Code']
|
2752
|
+
message = response['Response']['Error']['Message']
|
2753
|
+
reqid = response['Response']['RequestId']
|
2754
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2755
|
+
end
|
2756
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2757
|
+
raise e
|
2758
|
+
rescue StandardError => e
|
2759
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2760
|
+
end
|
2761
|
+
|
2762
|
+
# 释放一个或多个弹性公网IP(简称 EIP)。
|
2763
|
+
# 该操作不可逆,释放后 EIP 关联的 IP 地址将不再属于您的名下。
|
2764
|
+
# 只有状态为 UNBIND 的 EIP 才能进行释放操作。
|
2765
|
+
|
2766
|
+
# @param request: Request instance for ReleaseAddresses.
|
2767
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ReleaseAddressesRequest`
|
2768
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ReleaseAddressesResponse`
|
2769
|
+
def ReleaseAddresses(request)
|
2770
|
+
body = send_request('ReleaseAddresses', request.serialize)
|
2771
|
+
response = JSON.parse(body)
|
2772
|
+
if response['Response'].key?('Error') == false
|
2773
|
+
model = ReleaseAddressesResponse.new
|
2774
|
+
model.deserialize(response['Response'])
|
2775
|
+
model
|
2776
|
+
else
|
2777
|
+
code = response['Response']['Error']['Code']
|
2778
|
+
message = response['Response']['Error']['Message']
|
2779
|
+
reqid = response['Response']['RequestId']
|
2780
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2781
|
+
end
|
2782
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2783
|
+
raise e
|
2784
|
+
rescue StandardError => e
|
2785
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2786
|
+
end
|
2787
|
+
|
2788
|
+
# 本接口(UnassignIpv6Addresses)用于释放弹性网卡IPv6地址。
|
2789
|
+
|
2790
|
+
# @param request: Request instance for ReleaseIpv6Addresses.
|
2791
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ReleaseIpv6AddressesRequest`
|
2792
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ReleaseIpv6AddressesResponse`
|
2793
|
+
def ReleaseIpv6Addresses(request)
|
2794
|
+
body = send_request('ReleaseIpv6Addresses', request.serialize)
|
2795
|
+
response = JSON.parse(body)
|
2796
|
+
if response['Response'].key?('Error') == false
|
2797
|
+
model = ReleaseIpv6AddressesResponse.new
|
2798
|
+
model.deserialize(response['Response'])
|
2799
|
+
model
|
2800
|
+
else
|
2801
|
+
code = response['Response']['Error']['Code']
|
2802
|
+
message = response['Response']['Error']['Message']
|
2803
|
+
reqid = response['Response']['RequestId']
|
2804
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2805
|
+
end
|
2806
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2807
|
+
raise e
|
2808
|
+
rescue StandardError => e
|
2809
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2810
|
+
end
|
2811
|
+
|
2812
|
+
# 弹性网卡退还内网 IP。
|
2813
|
+
# 退还弹性网卡上的辅助内网IP,接口自动解关联弹性公网 IP。不能退还弹性网卡的主内网IP。
|
2814
|
+
|
2815
|
+
# @param request: Request instance for RemovePrivateIpAddresses.
|
2816
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::RemovePrivateIpAddressesRequest`
|
2817
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::RemovePrivateIpAddressesResponse`
|
2818
|
+
def RemovePrivateIpAddresses(request)
|
2819
|
+
body = send_request('RemovePrivateIpAddresses', request.serialize)
|
2820
|
+
response = JSON.parse(body)
|
2821
|
+
if response['Response'].key?('Error') == false
|
2822
|
+
model = RemovePrivateIpAddressesResponse.new
|
2823
|
+
model.deserialize(response['Response'])
|
2824
|
+
model
|
2825
|
+
else
|
2826
|
+
code = response['Response']['Error']['Code']
|
2827
|
+
message = response['Response']['Error']['Message']
|
2828
|
+
reqid = response['Response']['RequestId']
|
2829
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2830
|
+
end
|
2831
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2832
|
+
raise e
|
2833
|
+
rescue StandardError => e
|
2834
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2835
|
+
end
|
2836
|
+
|
2837
|
+
# 修改子网关联的路由表,一个子网只能关联一个路由表。
|
2838
|
+
|
2839
|
+
# @param request: Request instance for ReplaceRouteTableAssociation.
|
2840
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ReplaceRouteTableAssociationRequest`
|
2841
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ReplaceRouteTableAssociationResponse`
|
2842
|
+
def ReplaceRouteTableAssociation(request)
|
2843
|
+
body = send_request('ReplaceRouteTableAssociation', request.serialize)
|
2844
|
+
response = JSON.parse(body)
|
2845
|
+
if response['Response'].key?('Error') == false
|
2846
|
+
model = ReplaceRouteTableAssociationResponse.new
|
2847
|
+
model.deserialize(response['Response'])
|
2848
|
+
model
|
2849
|
+
else
|
2850
|
+
code = response['Response']['Error']['Code']
|
2851
|
+
message = response['Response']['Error']['Message']
|
2852
|
+
reqid = response['Response']['RequestId']
|
2853
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2854
|
+
end
|
2855
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2856
|
+
raise e
|
2857
|
+
rescue StandardError => e
|
2858
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2859
|
+
end
|
2860
|
+
|
2861
|
+
# 替换路由策略
|
2862
|
+
|
2863
|
+
# @param request: Request instance for ReplaceRoutes.
|
2864
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ReplaceRoutesRequest`
|
2865
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ReplaceRoutesResponse`
|
2866
|
+
def ReplaceRoutes(request)
|
2867
|
+
body = send_request('ReplaceRoutes', request.serialize)
|
2868
|
+
response = JSON.parse(body)
|
2869
|
+
if response['Response'].key?('Error') == false
|
2870
|
+
model = ReplaceRoutesResponse.new
|
2871
|
+
model.deserialize(response['Response'])
|
2872
|
+
model
|
2873
|
+
else
|
2874
|
+
code = response['Response']['Error']['Code']
|
2875
|
+
message = response['Response']['Error']['Message']
|
2876
|
+
reqid = response['Response']['RequestId']
|
2877
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2878
|
+
end
|
2879
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2880
|
+
raise e
|
2881
|
+
rescue StandardError => e
|
2882
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2883
|
+
end
|
2884
|
+
|
2885
|
+
# 替换单条安全组路由规则, 单个请求中只能替换单个方向的一条规则, 必须要指定索引(PolicyIndex)。
|
2886
|
+
|
2887
|
+
# @param request: Request instance for ReplaceSecurityGroupPolicy.
|
2888
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ReplaceSecurityGroupPolicyRequest`
|
2889
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ReplaceSecurityGroupPolicyResponse`
|
2890
|
+
def ReplaceSecurityGroupPolicy(request)
|
2891
|
+
body = send_request('ReplaceSecurityGroupPolicy', request.serialize)
|
2892
|
+
response = JSON.parse(body)
|
2893
|
+
if response['Response'].key?('Error') == false
|
2894
|
+
model = ReplaceSecurityGroupPolicyResponse.new
|
2895
|
+
model.deserialize(response['Response'])
|
2896
|
+
model
|
2897
|
+
else
|
2898
|
+
code = response['Response']['Error']['Code']
|
2899
|
+
message = response['Response']['Error']['Message']
|
2900
|
+
reqid = response['Response']['RequestId']
|
2901
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2902
|
+
end
|
2903
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2904
|
+
raise e
|
2905
|
+
rescue StandardError => e
|
2906
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2907
|
+
end
|
2908
|
+
|
2909
|
+
# 重装实例,若指定了ImageId参数,则使用指定的镜像重装;否则按照当前实例使用的镜像进行重装;若未指定密码,则密码通过站内信形式随后发送。
|
2910
|
+
|
2911
|
+
# @param request: Request instance for ResetInstances.
|
2912
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ResetInstancesRequest`
|
2913
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ResetInstancesResponse`
|
2914
|
+
def ResetInstances(request)
|
2915
|
+
body = send_request('ResetInstances', request.serialize)
|
2916
|
+
response = JSON.parse(body)
|
2917
|
+
if response['Response'].key?('Error') == false
|
2918
|
+
model = ResetInstancesResponse.new
|
2919
|
+
model.deserialize(response['Response'])
|
2920
|
+
model
|
2921
|
+
else
|
2922
|
+
code = response['Response']['Error']['Code']
|
2923
|
+
message = response['Response']['Error']['Message']
|
2924
|
+
reqid = response['Response']['RequestId']
|
2925
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2926
|
+
end
|
2927
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2928
|
+
raise e
|
2929
|
+
rescue StandardError => e
|
2930
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2931
|
+
end
|
2932
|
+
|
2933
|
+
# 重置实例的最大带宽上限。
|
2934
|
+
|
2935
|
+
# @param request: Request instance for ResetInstancesMaxBandwidth.
|
2936
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ResetInstancesMaxBandwidthRequest`
|
2937
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ResetInstancesMaxBandwidthResponse`
|
2938
|
+
def ResetInstancesMaxBandwidth(request)
|
2939
|
+
body = send_request('ResetInstancesMaxBandwidth', request.serialize)
|
2940
|
+
response = JSON.parse(body)
|
2941
|
+
if response['Response'].key?('Error') == false
|
2942
|
+
model = ResetInstancesMaxBandwidthResponse.new
|
2943
|
+
model.deserialize(response['Response'])
|
2944
|
+
model
|
2945
|
+
else
|
2946
|
+
code = response['Response']['Error']['Code']
|
2947
|
+
message = response['Response']['Error']['Message']
|
2948
|
+
reqid = response['Response']['RequestId']
|
2949
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2950
|
+
end
|
2951
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2952
|
+
raise e
|
2953
|
+
rescue StandardError => e
|
2954
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2955
|
+
end
|
2956
|
+
|
2957
|
+
# 重置处于运行中状态的实例的密码,需要显式指定强制关机参数ForceStop。如果没有显式指定强制关机参数,则只有处于关机状态的实例才允许执行重置密码操作。
|
2958
|
+
|
2959
|
+
# @param request: Request instance for ResetInstancesPassword.
|
2960
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ResetInstancesPasswordRequest`
|
2961
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ResetInstancesPasswordResponse`
|
2962
|
+
def ResetInstancesPassword(request)
|
2963
|
+
body = send_request('ResetInstancesPassword', request.serialize)
|
2964
|
+
response = JSON.parse(body)
|
2965
|
+
if response['Response'].key?('Error') == false
|
2966
|
+
model = ResetInstancesPasswordResponse.new
|
2967
|
+
model.deserialize(response['Response'])
|
2968
|
+
model
|
2969
|
+
else
|
2970
|
+
code = response['Response']['Error']['Code']
|
2971
|
+
message = response['Response']['Error']['Message']
|
2972
|
+
reqid = response['Response']['RequestId']
|
2973
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2974
|
+
end
|
2975
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
2976
|
+
raise e
|
2977
|
+
rescue StandardError => e
|
2978
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
2979
|
+
end
|
2980
|
+
|
2981
|
+
# 对某个路由表名称和所有路由策略(Route)进行重新设置
|
2982
|
+
|
2983
|
+
# @param request: Request instance for ResetRoutes.
|
2984
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::ResetRoutesRequest`
|
2985
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::ResetRoutesResponse`
|
2986
|
+
def ResetRoutes(request)
|
2987
|
+
body = send_request('ResetRoutes', request.serialize)
|
2988
|
+
response = JSON.parse(body)
|
2989
|
+
if response['Response'].key?('Error') == false
|
2990
|
+
model = ResetRoutesResponse.new
|
2991
|
+
model.deserialize(response['Response'])
|
2992
|
+
model
|
2993
|
+
else
|
2994
|
+
code = response['Response']['Error']['Code']
|
2995
|
+
message = response['Response']['Error']['Message']
|
2996
|
+
reqid = response['Response']['RequestId']
|
2997
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
2998
|
+
end
|
2999
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3000
|
+
raise e
|
3001
|
+
rescue StandardError => e
|
3002
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3003
|
+
end
|
3004
|
+
|
3005
|
+
# 创建ECM实例。
|
3006
|
+
|
3007
|
+
# @param request: Request instance for RunInstances.
|
3008
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::RunInstancesRequest`
|
3009
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::RunInstancesResponse`
|
3010
|
+
def RunInstances(request)
|
3011
|
+
body = send_request('RunInstances', request.serialize)
|
3012
|
+
response = JSON.parse(body)
|
3013
|
+
if response['Response'].key?('Error') == false
|
3014
|
+
model = RunInstancesResponse.new
|
3015
|
+
model.deserialize(response['Response'])
|
3016
|
+
model
|
3017
|
+
else
|
3018
|
+
code = response['Response']['Error']['Code']
|
3019
|
+
message = response['Response']['Error']['Message']
|
3020
|
+
reqid = response['Response']['RequestId']
|
3021
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
3022
|
+
end
|
3023
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3024
|
+
raise e
|
3025
|
+
rescue StandardError => e
|
3026
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3027
|
+
end
|
3028
|
+
|
3029
|
+
# 设置负载均衡实例的安全组。
|
3030
|
+
|
3031
|
+
# @param request: Request instance for SetLoadBalancerSecurityGroups.
|
3032
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::SetLoadBalancerSecurityGroupsRequest`
|
3033
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::SetLoadBalancerSecurityGroupsResponse`
|
3034
|
+
def SetLoadBalancerSecurityGroups(request)
|
3035
|
+
body = send_request('SetLoadBalancerSecurityGroups', request.serialize)
|
3036
|
+
response = JSON.parse(body)
|
3037
|
+
if response['Response'].key?('Error') == false
|
3038
|
+
model = SetLoadBalancerSecurityGroupsResponse.new
|
3039
|
+
model.deserialize(response['Response'])
|
3040
|
+
model
|
3041
|
+
else
|
3042
|
+
code = response['Response']['Error']['Code']
|
3043
|
+
message = response['Response']['Error']['Message']
|
3044
|
+
reqid = response['Response']['RequestId']
|
3045
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
3046
|
+
end
|
3047
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3048
|
+
raise e
|
3049
|
+
rescue StandardError => e
|
3050
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3051
|
+
end
|
3052
|
+
|
3053
|
+
# 绑定或解绑一个安全组到多个负载均衡实例。
|
3054
|
+
|
3055
|
+
# @param request: Request instance for SetSecurityGroupForLoadbalancers.
|
3056
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::SetSecurityGroupForLoadbalancersRequest`
|
3057
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::SetSecurityGroupForLoadbalancersResponse`
|
3058
|
+
def SetSecurityGroupForLoadbalancers(request)
|
3059
|
+
body = send_request('SetSecurityGroupForLoadbalancers', request.serialize)
|
3060
|
+
response = JSON.parse(body)
|
3061
|
+
if response['Response'].key?('Error') == false
|
3062
|
+
model = SetSecurityGroupForLoadbalancersResponse.new
|
3063
|
+
model.deserialize(response['Response'])
|
3064
|
+
model
|
3065
|
+
else
|
3066
|
+
code = response['Response']['Error']['Code']
|
3067
|
+
message = response['Response']['Error']['Message']
|
3068
|
+
reqid = response['Response']['RequestId']
|
3069
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
3070
|
+
end
|
3071
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3072
|
+
raise e
|
3073
|
+
rescue StandardError => e
|
3074
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3075
|
+
end
|
3076
|
+
|
3077
|
+
# 只有状态为STOPPED的实例才可以进行此操作;接口调用成功时,实例会进入STARTING状态;启动实例成功时,实例会进入RUNNING状态。
|
3078
|
+
|
3079
|
+
# @param request: Request instance for StartInstances.
|
3080
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::StartInstancesRequest`
|
3081
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::StartInstancesResponse`
|
3082
|
+
def StartInstances(request)
|
3083
|
+
body = send_request('StartInstances', request.serialize)
|
3084
|
+
response = JSON.parse(body)
|
3085
|
+
if response['Response'].key?('Error') == false
|
3086
|
+
model = StartInstancesResponse.new
|
3087
|
+
model.deserialize(response['Response'])
|
3088
|
+
model
|
3089
|
+
else
|
3090
|
+
code = response['Response']['Error']['Code']
|
3091
|
+
message = response['Response']['Error']['Message']
|
3092
|
+
reqid = response['Response']['RequestId']
|
3093
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
3094
|
+
end
|
3095
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3096
|
+
raise e
|
3097
|
+
rescue StandardError => e
|
3098
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3099
|
+
end
|
3100
|
+
|
3101
|
+
# 只有处于"RUNNING"状态的实例才能够进行关机操作;
|
3102
|
+
# 调用成功时,实例会进入STOPPING状态;关闭实例成功时,实例会进入STOPPED状态;
|
3103
|
+
# 支持强制关闭,强制关机的效果等同于关闭物理计算机的电源开关,强制关机可能会导致数据丢失或文件系统损坏,请仅在服务器不能正常关机时使用。
|
3104
|
+
|
3105
|
+
# @param request: Request instance for StopInstances.
|
3106
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::StopInstancesRequest`
|
3107
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::StopInstancesResponse`
|
3108
|
+
def StopInstances(request)
|
3109
|
+
body = send_request('StopInstances', request.serialize)
|
3110
|
+
response = JSON.parse(body)
|
3111
|
+
if response['Response'].key?('Error') == false
|
3112
|
+
model = StopInstancesResponse.new
|
3113
|
+
model.deserialize(response['Response'])
|
3114
|
+
model
|
3115
|
+
else
|
3116
|
+
code = response['Response']['Error']['Code']
|
3117
|
+
message = response['Response']['Error']['Message']
|
3118
|
+
reqid = response['Response']['RequestId']
|
3119
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
3120
|
+
end
|
3121
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3122
|
+
raise e
|
3123
|
+
rescue StandardError => e
|
3124
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3125
|
+
end
|
3126
|
+
|
3127
|
+
# 本接口(TerminateDisks)用于退还云硬盘。
|
3128
|
+
|
3129
|
+
# * 不再使用的云盘,可通过本接口主动退还。
|
3130
|
+
# * 本接口支持退还预付费云盘和按小时后付费云盘。按小时后付费云盘可直接退还,预付费云盘需符合退还规则。
|
3131
|
+
# * 支持批量操作,每次请求批量云硬盘的上限为50。如果批量云盘存在不允许操作的,请求会以特定错误码返回。
|
3132
|
+
|
3133
|
+
# @param request: Request instance for TerminateDisks.
|
3134
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::TerminateDisksRequest`
|
3135
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::TerminateDisksResponse`
|
3136
|
+
def TerminateDisks(request)
|
3137
|
+
body = send_request('TerminateDisks', request.serialize)
|
3138
|
+
response = JSON.parse(body)
|
3139
|
+
if response['Response'].key?('Error') == false
|
3140
|
+
model = TerminateDisksResponse.new
|
3141
|
+
model.deserialize(response['Response'])
|
3142
|
+
model
|
3143
|
+
else
|
3144
|
+
code = response['Response']['Error']['Code']
|
3145
|
+
message = response['Response']['Error']['Message']
|
3146
|
+
reqid = response['Response']['RequestId']
|
3147
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
3148
|
+
end
|
3149
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3150
|
+
raise e
|
3151
|
+
rescue StandardError => e
|
3152
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3153
|
+
end
|
3154
|
+
|
3155
|
+
# 销毁实例
|
3156
|
+
|
3157
|
+
# @param request: Request instance for TerminateInstances.
|
3158
|
+
# @type request: :class:`Tencentcloud::ecm::V20190719::TerminateInstancesRequest`
|
3159
|
+
# @rtype: :class:`Tencentcloud::ecm::V20190719::TerminateInstancesResponse`
|
3160
|
+
def TerminateInstances(request)
|
3161
|
+
body = send_request('TerminateInstances', request.serialize)
|
3162
|
+
response = JSON.parse(body)
|
3163
|
+
if response['Response'].key?('Error') == false
|
3164
|
+
model = TerminateInstancesResponse.new
|
3165
|
+
model.deserialize(response['Response'])
|
3166
|
+
model
|
3167
|
+
else
|
3168
|
+
code = response['Response']['Error']['Code']
|
3169
|
+
message = response['Response']['Error']['Message']
|
3170
|
+
reqid = response['Response']['RequestId']
|
3171
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
3172
|
+
end
|
3173
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
3174
|
+
raise e
|
3175
|
+
rescue StandardError => e
|
3176
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
3177
|
+
end
|
3178
|
+
|
3179
|
+
|
3180
|
+
end
|
3181
|
+
end
|
3182
|
+
end
|
3183
|
+
end
|