huaweicloudsdkgaussdb 3.1.144__py2.py3-none-any.whl → 3.1.145__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- huaweicloudsdkgaussdb/v3/__init__.py +6 -0
- huaweicloudsdkgaussdb/v3/gaussdb_async_client.py +549 -405
- huaweicloudsdkgaussdb/v3/gaussdb_client.py +549 -405
- huaweicloudsdkgaussdb/v3/model/__init__.py +6 -0
- huaweicloudsdkgaussdb/v3/model/delete_taurus_db_node_processes_request.py +196 -0
- huaweicloudsdkgaussdb/v3/model/delete_taurus_db_node_processes_request_body.py +114 -0
- huaweicloudsdkgaussdb/v3/model/delete_taurus_db_node_processes_response.py +145 -0
- huaweicloudsdkgaussdb/v3/model/list_taurus_db_node_processes_request.py +229 -0
- huaweicloudsdkgaussdb/v3/model/list_taurus_db_node_processes_response.py +145 -0
- huaweicloudsdkgaussdb/v3/model/taurus_db_process_info.py +310 -0
- {huaweicloudsdkgaussdb-3.1.144.dist-info → huaweicloudsdkgaussdb-3.1.145.dist-info}/METADATA +2 -2
- {huaweicloudsdkgaussdb-3.1.144.dist-info → huaweicloudsdkgaussdb-3.1.145.dist-info}/RECORD +15 -9
- {huaweicloudsdkgaussdb-3.1.144.dist-info → huaweicloudsdkgaussdb-3.1.145.dist-info}/LICENSE +0 -0
- {huaweicloudsdkgaussdb-3.1.144.dist-info → huaweicloudsdkgaussdb-3.1.145.dist-info}/WHEEL +0 -0
- {huaweicloudsdkgaussdb-3.1.144.dist-info → huaweicloudsdkgaussdb-3.1.145.dist-info}/top_level.txt +0 -0
@@ -2087,6 +2087,75 @@ class GaussDBClient(Client):
|
|
2087
2087
|
|
2088
2088
|
return http_info
|
2089
2089
|
|
2090
|
+
def delete_sql_filter_rule(self, request):
|
2091
|
+
r"""删除SQL限流规则
|
2092
|
+
|
2093
|
+
删除SQL限流规则。
|
2094
|
+
|
2095
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
2096
|
+
|
2097
|
+
:param request: Request instance for DeleteSqlFilterRule
|
2098
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.DeleteSqlFilterRuleRequest`
|
2099
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.DeleteSqlFilterRuleResponse`
|
2100
|
+
"""
|
2101
|
+
http_info = self._delete_sql_filter_rule_http_info(request)
|
2102
|
+
return self._call_api(**http_info)
|
2103
|
+
|
2104
|
+
def delete_sql_filter_rule_invoker(self, request):
|
2105
|
+
http_info = self._delete_sql_filter_rule_http_info(request)
|
2106
|
+
return SyncInvoker(self, http_info)
|
2107
|
+
|
2108
|
+
@classmethod
|
2109
|
+
def _delete_sql_filter_rule_http_info(cls, request):
|
2110
|
+
http_info = {
|
2111
|
+
"method": "DELETE",
|
2112
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/rules",
|
2113
|
+
"request_type": request.__class__.__name__,
|
2114
|
+
"response_type": "DeleteSqlFilterRuleResponse"
|
2115
|
+
}
|
2116
|
+
|
2117
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
2118
|
+
|
2119
|
+
cname = None
|
2120
|
+
|
2121
|
+
collection_formats = {}
|
2122
|
+
|
2123
|
+
path_params = {}
|
2124
|
+
if 'instance_id' in local_var_params:
|
2125
|
+
path_params['instance_id'] = local_var_params['instance_id']
|
2126
|
+
|
2127
|
+
query_params = []
|
2128
|
+
|
2129
|
+
header_params = {}
|
2130
|
+
if 'x_language' in local_var_params:
|
2131
|
+
header_params['X-Language'] = local_var_params['x_language']
|
2132
|
+
|
2133
|
+
form_params = {}
|
2134
|
+
|
2135
|
+
body = None
|
2136
|
+
if 'body' in local_var_params:
|
2137
|
+
body = local_var_params['body']
|
2138
|
+
if isinstance(request, SdkStreamRequest):
|
2139
|
+
body = request.get_file_stream()
|
2140
|
+
|
2141
|
+
response_headers = []
|
2142
|
+
|
2143
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
2144
|
+
['application/json;charset=UTF-8'])
|
2145
|
+
|
2146
|
+
auth_settings = []
|
2147
|
+
|
2148
|
+
http_info["cname"] = cname
|
2149
|
+
http_info["collection_formats"] = collection_formats
|
2150
|
+
http_info["path_params"] = path_params
|
2151
|
+
http_info["query_params"] = query_params
|
2152
|
+
http_info["header_params"] = header_params
|
2153
|
+
http_info["post_params"] = form_params
|
2154
|
+
http_info["body"] = body
|
2155
|
+
http_info["response_headers"] = response_headers
|
2156
|
+
|
2157
|
+
return http_info
|
2158
|
+
|
2090
2159
|
def delete_task_record(self, request):
|
2091
2160
|
r"""删除指定任务记录
|
2092
2161
|
|
@@ -2154,6 +2223,77 @@ class GaussDBClient(Client):
|
|
2154
2223
|
|
2155
2224
|
return http_info
|
2156
2225
|
|
2226
|
+
def delete_taurus_db_node_processes(self, request):
|
2227
|
+
r"""终止节点用户会话线程
|
2228
|
+
|
2229
|
+
终止TaurusDB节点中指定的用户会话线程,执行时将排除传入的内部会话线程。
|
2230
|
+
|
2231
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
2232
|
+
|
2233
|
+
:param request: Request instance for DeleteTaurusDbNodeProcesses
|
2234
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.DeleteTaurusDbNodeProcessesRequest`
|
2235
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.DeleteTaurusDbNodeProcessesResponse`
|
2236
|
+
"""
|
2237
|
+
http_info = self._delete_taurus_db_node_processes_http_info(request)
|
2238
|
+
return self._call_api(**http_info)
|
2239
|
+
|
2240
|
+
def delete_taurus_db_node_processes_invoker(self, request):
|
2241
|
+
http_info = self._delete_taurus_db_node_processes_http_info(request)
|
2242
|
+
return SyncInvoker(self, http_info)
|
2243
|
+
|
2244
|
+
@classmethod
|
2245
|
+
def _delete_taurus_db_node_processes_http_info(cls, request):
|
2246
|
+
http_info = {
|
2247
|
+
"method": "DELETE",
|
2248
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/nodes/{node_id}/processes",
|
2249
|
+
"request_type": request.__class__.__name__,
|
2250
|
+
"response_type": "DeleteTaurusDbNodeProcessesResponse"
|
2251
|
+
}
|
2252
|
+
|
2253
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
2254
|
+
|
2255
|
+
cname = None
|
2256
|
+
|
2257
|
+
collection_formats = {}
|
2258
|
+
|
2259
|
+
path_params = {}
|
2260
|
+
if 'instance_id' in local_var_params:
|
2261
|
+
path_params['instance_id'] = local_var_params['instance_id']
|
2262
|
+
if 'node_id' in local_var_params:
|
2263
|
+
path_params['node_id'] = local_var_params['node_id']
|
2264
|
+
|
2265
|
+
query_params = []
|
2266
|
+
|
2267
|
+
header_params = {}
|
2268
|
+
if 'x_language' in local_var_params:
|
2269
|
+
header_params['X-Language'] = local_var_params['x_language']
|
2270
|
+
|
2271
|
+
form_params = {}
|
2272
|
+
|
2273
|
+
body = None
|
2274
|
+
if 'body' in local_var_params:
|
2275
|
+
body = local_var_params['body']
|
2276
|
+
if isinstance(request, SdkStreamRequest):
|
2277
|
+
body = request.get_file_stream()
|
2278
|
+
|
2279
|
+
response_headers = []
|
2280
|
+
|
2281
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
2282
|
+
['application/json;charset=UTF-8'])
|
2283
|
+
|
2284
|
+
auth_settings = []
|
2285
|
+
|
2286
|
+
http_info["cname"] = cname
|
2287
|
+
http_info["collection_formats"] = collection_formats
|
2288
|
+
http_info["path_params"] = path_params
|
2289
|
+
http_info["query_params"] = query_params
|
2290
|
+
http_info["header_params"] = header_params
|
2291
|
+
http_info["post_params"] = form_params
|
2292
|
+
http_info["body"] = body
|
2293
|
+
http_info["response_headers"] = response_headers
|
2294
|
+
|
2295
|
+
return http_info
|
2296
|
+
|
2157
2297
|
def describe_backup_encrypt_status(self, request):
|
2158
2298
|
r"""查询实例是否开启备份加密功能
|
2159
2299
|
|
@@ -4161,6 +4301,79 @@ class GaussDBClient(Client):
|
|
4161
4301
|
|
4162
4302
|
return http_info
|
4163
4303
|
|
4304
|
+
def list_taurus_db_node_processes(self, request):
|
4305
|
+
r"""查询节点用户会话线程
|
4306
|
+
|
4307
|
+
分页查询TaurusDB节点中的用户会话线程,对应于show processlist命令,返回结果不含内部会话线程。
|
4308
|
+
|
4309
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
4310
|
+
|
4311
|
+
:param request: Request instance for ListTaurusDbNodeProcesses
|
4312
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.ListTaurusDbNodeProcessesRequest`
|
4313
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.ListTaurusDbNodeProcessesResponse`
|
4314
|
+
"""
|
4315
|
+
http_info = self._list_taurus_db_node_processes_http_info(request)
|
4316
|
+
return self._call_api(**http_info)
|
4317
|
+
|
4318
|
+
def list_taurus_db_node_processes_invoker(self, request):
|
4319
|
+
http_info = self._list_taurus_db_node_processes_http_info(request)
|
4320
|
+
return SyncInvoker(self, http_info)
|
4321
|
+
|
4322
|
+
@classmethod
|
4323
|
+
def _list_taurus_db_node_processes_http_info(cls, request):
|
4324
|
+
http_info = {
|
4325
|
+
"method": "GET",
|
4326
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/nodes/{node_id}/processes",
|
4327
|
+
"request_type": request.__class__.__name__,
|
4328
|
+
"response_type": "ListTaurusDbNodeProcessesResponse"
|
4329
|
+
}
|
4330
|
+
|
4331
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
4332
|
+
|
4333
|
+
cname = None
|
4334
|
+
|
4335
|
+
collection_formats = {}
|
4336
|
+
|
4337
|
+
path_params = {}
|
4338
|
+
if 'instance_id' in local_var_params:
|
4339
|
+
path_params['instance_id'] = local_var_params['instance_id']
|
4340
|
+
if 'node_id' in local_var_params:
|
4341
|
+
path_params['node_id'] = local_var_params['node_id']
|
4342
|
+
|
4343
|
+
query_params = []
|
4344
|
+
if 'offset' in local_var_params:
|
4345
|
+
query_params.append(('offset', local_var_params['offset']))
|
4346
|
+
if 'limit' in local_var_params:
|
4347
|
+
query_params.append(('limit', local_var_params['limit']))
|
4348
|
+
|
4349
|
+
header_params = {}
|
4350
|
+
if 'x_language' in local_var_params:
|
4351
|
+
header_params['X-Language'] = local_var_params['x_language']
|
4352
|
+
|
4353
|
+
form_params = {}
|
4354
|
+
|
4355
|
+
body = None
|
4356
|
+
if isinstance(request, SdkStreamRequest):
|
4357
|
+
body = request.get_file_stream()
|
4358
|
+
|
4359
|
+
response_headers = []
|
4360
|
+
|
4361
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
4362
|
+
['application/json'])
|
4363
|
+
|
4364
|
+
auth_settings = []
|
4365
|
+
|
4366
|
+
http_info["cname"] = cname
|
4367
|
+
http_info["collection_formats"] = collection_formats
|
4368
|
+
http_info["path_params"] = path_params
|
4369
|
+
http_info["query_params"] = query_params
|
4370
|
+
http_info["header_params"] = header_params
|
4371
|
+
http_info["post_params"] = form_params
|
4372
|
+
http_info["body"] = body
|
4373
|
+
http_info["response_headers"] = response_headers
|
4374
|
+
|
4375
|
+
return http_info
|
4376
|
+
|
4164
4377
|
def modify_backup_encrypt_status(self, request):
|
4165
4378
|
r"""打开或关闭备份加密
|
4166
4379
|
|
@@ -5129,31 +5342,31 @@ class GaussDBClient(Client):
|
|
5129
5342
|
|
5130
5343
|
return http_info
|
5131
5344
|
|
5132
|
-
def
|
5133
|
-
r"""
|
5345
|
+
def set_sql_filter_rule(self, request):
|
5346
|
+
r"""设置SQL限流规则
|
5134
5347
|
|
5135
|
-
|
5348
|
+
设置SQL限流规则。
|
5136
5349
|
|
5137
5350
|
Please refer to HUAWEI cloud API Explorer for details.
|
5138
5351
|
|
5139
|
-
:param request: Request instance for
|
5140
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.
|
5141
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.
|
5352
|
+
:param request: Request instance for SetSqlFilterRule
|
5353
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.SetSqlFilterRuleRequest`
|
5354
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.SetSqlFilterRuleResponse`
|
5142
5355
|
"""
|
5143
|
-
http_info = self.
|
5356
|
+
http_info = self._set_sql_filter_rule_http_info(request)
|
5144
5357
|
return self._call_api(**http_info)
|
5145
5358
|
|
5146
|
-
def
|
5147
|
-
http_info = self.
|
5359
|
+
def set_sql_filter_rule_invoker(self, request):
|
5360
|
+
http_info = self._set_sql_filter_rule_http_info(request)
|
5148
5361
|
return SyncInvoker(self, http_info)
|
5149
5362
|
|
5150
5363
|
@classmethod
|
5151
|
-
def
|
5364
|
+
def _set_sql_filter_rule_http_info(cls, request):
|
5152
5365
|
http_info = {
|
5153
|
-
"method": "
|
5154
|
-
"resource_path": "/v3/{project_id}/
|
5366
|
+
"method": "PUT",
|
5367
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/rules",
|
5155
5368
|
"request_type": request.__class__.__name__,
|
5156
|
-
"response_type": "
|
5369
|
+
"response_type": "SetSqlFilterRuleResponse"
|
5157
5370
|
}
|
5158
5371
|
|
5159
5372
|
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
@@ -5175,13 +5388,15 @@ class GaussDBClient(Client):
|
|
5175
5388
|
form_params = {}
|
5176
5389
|
|
5177
5390
|
body = None
|
5391
|
+
if 'body' in local_var_params:
|
5392
|
+
body = local_var_params['body']
|
5178
5393
|
if isinstance(request, SdkStreamRequest):
|
5179
5394
|
body = request.get_file_stream()
|
5180
5395
|
|
5181
5396
|
response_headers = []
|
5182
5397
|
|
5183
5398
|
header_params['Content-Type'] = http_utils.select_header_content_type(
|
5184
|
-
['application/json'])
|
5399
|
+
['application/json;charset=UTF-8'])
|
5185
5400
|
|
5186
5401
|
auth_settings = []
|
5187
5402
|
|
@@ -5196,31 +5411,31 @@ class GaussDBClient(Client):
|
|
5196
5411
|
|
5197
5412
|
return http_info
|
5198
5413
|
|
5199
|
-
def
|
5200
|
-
r"""
|
5414
|
+
def show_audit_log(self, request):
|
5415
|
+
r"""查询全量SQL开关状态
|
5201
5416
|
|
5202
|
-
|
5417
|
+
查询全量SQL开关状态。
|
5203
5418
|
|
5204
5419
|
Please refer to HUAWEI cloud API Explorer for details.
|
5205
5420
|
|
5206
|
-
:param request: Request instance for
|
5207
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.
|
5208
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.
|
5421
|
+
:param request: Request instance for ShowAuditLog
|
5422
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.ShowAuditLogRequest`
|
5423
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.ShowAuditLogResponse`
|
5209
5424
|
"""
|
5210
|
-
http_info = self.
|
5425
|
+
http_info = self._show_audit_log_http_info(request)
|
5211
5426
|
return self._call_api(**http_info)
|
5212
5427
|
|
5213
|
-
def
|
5214
|
-
http_info = self.
|
5428
|
+
def show_audit_log_invoker(self, request):
|
5429
|
+
http_info = self._show_audit_log_http_info(request)
|
5215
5430
|
return SyncInvoker(self, http_info)
|
5216
5431
|
|
5217
5432
|
@classmethod
|
5218
|
-
def
|
5433
|
+
def _show_audit_log_http_info(cls, request):
|
5219
5434
|
http_info = {
|
5220
5435
|
"method": "GET",
|
5221
|
-
"resource_path": "/v3/{project_id}/
|
5436
|
+
"resource_path": "/v3/{project_id}/instance/{instance_id}/audit-log/switch-status",
|
5222
5437
|
"request_type": request.__class__.__name__,
|
5223
|
-
"response_type": "
|
5438
|
+
"response_type": "ShowAuditLogResponse"
|
5224
5439
|
}
|
5225
5440
|
|
5226
5441
|
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
@@ -5234,10 +5449,6 @@ class GaussDBClient(Client):
|
|
5234
5449
|
path_params['instance_id'] = local_var_params['instance_id']
|
5235
5450
|
|
5236
5451
|
query_params = []
|
5237
|
-
if 'limit' in local_var_params:
|
5238
|
-
query_params.append(('limit', local_var_params['limit']))
|
5239
|
-
if 'offset' in local_var_params:
|
5240
|
-
query_params.append(('offset', local_var_params['offset']))
|
5241
5452
|
|
5242
5453
|
header_params = {}
|
5243
5454
|
if 'x_language' in local_var_params:
|
@@ -5267,16 +5478,87 @@ class GaussDBClient(Client):
|
|
5267
5478
|
|
5268
5479
|
return http_info
|
5269
5480
|
|
5270
|
-
def
|
5271
|
-
r"""
|
5481
|
+
def show_auto_scaling_history(self, request):
|
5482
|
+
r"""查询自动变配历史记录.
|
5272
5483
|
|
5273
|
-
|
5484
|
+
查询自动变配历史记录.
|
5274
5485
|
|
5275
5486
|
Please refer to HUAWEI cloud API Explorer for details.
|
5276
5487
|
|
5277
|
-
:param request: Request instance for
|
5278
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.
|
5279
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.
|
5488
|
+
:param request: Request instance for ShowAutoScalingHistory
|
5489
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.ShowAutoScalingHistoryRequest`
|
5490
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.ShowAutoScalingHistoryResponse`
|
5491
|
+
"""
|
5492
|
+
http_info = self._show_auto_scaling_history_http_info(request)
|
5493
|
+
return self._call_api(**http_info)
|
5494
|
+
|
5495
|
+
def show_auto_scaling_history_invoker(self, request):
|
5496
|
+
http_info = self._show_auto_scaling_history_http_info(request)
|
5497
|
+
return SyncInvoker(self, http_info)
|
5498
|
+
|
5499
|
+
@classmethod
|
5500
|
+
def _show_auto_scaling_history_http_info(cls, request):
|
5501
|
+
http_info = {
|
5502
|
+
"method": "GET",
|
5503
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/auto-scaling/history",
|
5504
|
+
"request_type": request.__class__.__name__,
|
5505
|
+
"response_type": "ShowAutoScalingHistoryResponse"
|
5506
|
+
}
|
5507
|
+
|
5508
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
5509
|
+
|
5510
|
+
cname = None
|
5511
|
+
|
5512
|
+
collection_formats = {}
|
5513
|
+
|
5514
|
+
path_params = {}
|
5515
|
+
if 'instance_id' in local_var_params:
|
5516
|
+
path_params['instance_id'] = local_var_params['instance_id']
|
5517
|
+
|
5518
|
+
query_params = []
|
5519
|
+
if 'limit' in local_var_params:
|
5520
|
+
query_params.append(('limit', local_var_params['limit']))
|
5521
|
+
if 'offset' in local_var_params:
|
5522
|
+
query_params.append(('offset', local_var_params['offset']))
|
5523
|
+
|
5524
|
+
header_params = {}
|
5525
|
+
if 'x_language' in local_var_params:
|
5526
|
+
header_params['X-Language'] = local_var_params['x_language']
|
5527
|
+
|
5528
|
+
form_params = {}
|
5529
|
+
|
5530
|
+
body = None
|
5531
|
+
if isinstance(request, SdkStreamRequest):
|
5532
|
+
body = request.get_file_stream()
|
5533
|
+
|
5534
|
+
response_headers = []
|
5535
|
+
|
5536
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
5537
|
+
['application/json'])
|
5538
|
+
|
5539
|
+
auth_settings = []
|
5540
|
+
|
5541
|
+
http_info["cname"] = cname
|
5542
|
+
http_info["collection_formats"] = collection_formats
|
5543
|
+
http_info["path_params"] = path_params
|
5544
|
+
http_info["query_params"] = query_params
|
5545
|
+
http_info["header_params"] = header_params
|
5546
|
+
http_info["post_params"] = form_params
|
5547
|
+
http_info["body"] = body
|
5548
|
+
http_info["response_headers"] = response_headers
|
5549
|
+
|
5550
|
+
return http_info
|
5551
|
+
|
5552
|
+
def show_auto_scaling_policy(self, request):
|
5553
|
+
r"""查询自动变配
|
5554
|
+
|
5555
|
+
查询自动变配。
|
5556
|
+
|
5557
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
5558
|
+
|
5559
|
+
:param request: Request instance for ShowAutoScalingPolicy
|
5560
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.ShowAutoScalingPolicyRequest`
|
5561
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.ShowAutoScalingPolicyResponse`
|
5280
5562
|
"""
|
5281
5563
|
http_info = self._show_auto_scaling_policy_http_info(request)
|
5282
5564
|
return self._call_api(**http_info)
|
@@ -7349,6 +7631,144 @@ class GaussDBClient(Client):
|
|
7349
7631
|
|
7350
7632
|
return http_info
|
7351
7633
|
|
7634
|
+
def show_sql_filter_control(self, request):
|
7635
|
+
r"""查询SQL限流开关状态
|
7636
|
+
|
7637
|
+
查询SQL限流开关状态。
|
7638
|
+
|
7639
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
7640
|
+
|
7641
|
+
:param request: Request instance for ShowSqlFilterControl
|
7642
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterControlRequest`
|
7643
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterControlResponse`
|
7644
|
+
"""
|
7645
|
+
http_info = self._show_sql_filter_control_http_info(request)
|
7646
|
+
return self._call_api(**http_info)
|
7647
|
+
|
7648
|
+
def show_sql_filter_control_invoker(self, request):
|
7649
|
+
http_info = self._show_sql_filter_control_http_info(request)
|
7650
|
+
return SyncInvoker(self, http_info)
|
7651
|
+
|
7652
|
+
@classmethod
|
7653
|
+
def _show_sql_filter_control_http_info(cls, request):
|
7654
|
+
http_info = {
|
7655
|
+
"method": "GET",
|
7656
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/switch",
|
7657
|
+
"request_type": request.__class__.__name__,
|
7658
|
+
"response_type": "ShowSqlFilterControlResponse"
|
7659
|
+
}
|
7660
|
+
|
7661
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
7662
|
+
|
7663
|
+
cname = None
|
7664
|
+
|
7665
|
+
collection_formats = {}
|
7666
|
+
|
7667
|
+
path_params = {}
|
7668
|
+
if 'instance_id' in local_var_params:
|
7669
|
+
path_params['instance_id'] = local_var_params['instance_id']
|
7670
|
+
|
7671
|
+
query_params = []
|
7672
|
+
|
7673
|
+
header_params = {}
|
7674
|
+
if 'x_language' in local_var_params:
|
7675
|
+
header_params['X-Language'] = local_var_params['x_language']
|
7676
|
+
|
7677
|
+
form_params = {}
|
7678
|
+
|
7679
|
+
body = None
|
7680
|
+
if isinstance(request, SdkStreamRequest):
|
7681
|
+
body = request.get_file_stream()
|
7682
|
+
|
7683
|
+
response_headers = []
|
7684
|
+
|
7685
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
7686
|
+
['application/json'])
|
7687
|
+
|
7688
|
+
auth_settings = []
|
7689
|
+
|
7690
|
+
http_info["cname"] = cname
|
7691
|
+
http_info["collection_formats"] = collection_formats
|
7692
|
+
http_info["path_params"] = path_params
|
7693
|
+
http_info["query_params"] = query_params
|
7694
|
+
http_info["header_params"] = header_params
|
7695
|
+
http_info["post_params"] = form_params
|
7696
|
+
http_info["body"] = body
|
7697
|
+
http_info["response_headers"] = response_headers
|
7698
|
+
|
7699
|
+
return http_info
|
7700
|
+
|
7701
|
+
def show_sql_filter_rule(self, request):
|
7702
|
+
r"""查询SQL限流规则
|
7703
|
+
|
7704
|
+
查询SQL限流规则。
|
7705
|
+
|
7706
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
7707
|
+
|
7708
|
+
:param request: Request instance for ShowSqlFilterRule
|
7709
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterRuleRequest`
|
7710
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterRuleResponse`
|
7711
|
+
"""
|
7712
|
+
http_info = self._show_sql_filter_rule_http_info(request)
|
7713
|
+
return self._call_api(**http_info)
|
7714
|
+
|
7715
|
+
def show_sql_filter_rule_invoker(self, request):
|
7716
|
+
http_info = self._show_sql_filter_rule_http_info(request)
|
7717
|
+
return SyncInvoker(self, http_info)
|
7718
|
+
|
7719
|
+
@classmethod
|
7720
|
+
def _show_sql_filter_rule_http_info(cls, request):
|
7721
|
+
http_info = {
|
7722
|
+
"method": "GET",
|
7723
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/rules",
|
7724
|
+
"request_type": request.__class__.__name__,
|
7725
|
+
"response_type": "ShowSqlFilterRuleResponse"
|
7726
|
+
}
|
7727
|
+
|
7728
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
7729
|
+
|
7730
|
+
cname = None
|
7731
|
+
|
7732
|
+
collection_formats = {}
|
7733
|
+
|
7734
|
+
path_params = {}
|
7735
|
+
if 'instance_id' in local_var_params:
|
7736
|
+
path_params['instance_id'] = local_var_params['instance_id']
|
7737
|
+
|
7738
|
+
query_params = []
|
7739
|
+
if 'node_id' in local_var_params:
|
7740
|
+
query_params.append(('node_id', local_var_params['node_id']))
|
7741
|
+
if 'sql_type' in local_var_params:
|
7742
|
+
query_params.append(('sql_type', local_var_params['sql_type']))
|
7743
|
+
|
7744
|
+
header_params = {}
|
7745
|
+
if 'x_language' in local_var_params:
|
7746
|
+
header_params['X-Language'] = local_var_params['x_language']
|
7747
|
+
|
7748
|
+
form_params = {}
|
7749
|
+
|
7750
|
+
body = None
|
7751
|
+
if isinstance(request, SdkStreamRequest):
|
7752
|
+
body = request.get_file_stream()
|
7753
|
+
|
7754
|
+
response_headers = []
|
7755
|
+
|
7756
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
7757
|
+
['application/json'])
|
7758
|
+
|
7759
|
+
auth_settings = []
|
7760
|
+
|
7761
|
+
http_info["cname"] = cname
|
7762
|
+
http_info["collection_formats"] = collection_formats
|
7763
|
+
http_info["path_params"] = path_params
|
7764
|
+
http_info["query_params"] = query_params
|
7765
|
+
http_info["header_params"] = header_params
|
7766
|
+
http_info["post_params"] = form_params
|
7767
|
+
http_info["body"] = body
|
7768
|
+
http_info["response_headers"] = response_headers
|
7769
|
+
|
7770
|
+
return http_info
|
7771
|
+
|
7352
7772
|
def shrink_gauss_my_sql_proxy(self, request):
|
7353
7773
|
r"""减少数据库代理节点的数量
|
7354
7774
|
|
@@ -9505,31 +9925,31 @@ class GaussDBClient(Client):
|
|
9505
9925
|
|
9506
9926
|
return http_info
|
9507
9927
|
|
9508
|
-
def
|
9509
|
-
r"""
|
9928
|
+
def update_sql_filter_control(self, request):
|
9929
|
+
r"""开启或者关闭SQL限流
|
9510
9930
|
|
9511
|
-
|
9931
|
+
开启或者关闭SQL限流。
|
9512
9932
|
|
9513
9933
|
Please refer to HUAWEI cloud API Explorer for details.
|
9514
9934
|
|
9515
|
-
:param request: Request instance for
|
9516
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.
|
9517
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.
|
9935
|
+
:param request: Request instance for UpdateSqlFilterControl
|
9936
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.UpdateSqlFilterControlRequest`
|
9937
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.UpdateSqlFilterControlResponse`
|
9518
9938
|
"""
|
9519
|
-
http_info = self.
|
9939
|
+
http_info = self._update_sql_filter_control_http_info(request)
|
9520
9940
|
return self._call_api(**http_info)
|
9521
9941
|
|
9522
|
-
def
|
9523
|
-
http_info = self.
|
9942
|
+
def update_sql_filter_control_invoker(self, request):
|
9943
|
+
http_info = self._update_sql_filter_control_http_info(request)
|
9524
9944
|
return SyncInvoker(self, http_info)
|
9525
9945
|
|
9526
9946
|
@classmethod
|
9527
|
-
def
|
9947
|
+
def _update_sql_filter_control_http_info(cls, request):
|
9528
9948
|
http_info = {
|
9529
|
-
"method": "
|
9530
|
-
"resource_path": "/v3/{project_id}/instances/{instance_id}/
|
9949
|
+
"method": "POST",
|
9950
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/switch",
|
9531
9951
|
"request_type": request.__class__.__name__,
|
9532
|
-
"response_type": "
|
9952
|
+
"response_type": "UpdateSqlFilterControlResponse"
|
9533
9953
|
}
|
9534
9954
|
|
9535
9955
|
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
@@ -9541,8 +9961,6 @@ class GaussDBClient(Client):
|
|
9541
9961
|
path_params = {}
|
9542
9962
|
if 'instance_id' in local_var_params:
|
9543
9963
|
path_params['instance_id'] = local_var_params['instance_id']
|
9544
|
-
if 'node_id' in local_var_params:
|
9545
|
-
path_params['node_id'] = local_var_params['node_id']
|
9546
9964
|
|
9547
9965
|
query_params = []
|
9548
9966
|
|
@@ -9576,22 +9994,93 @@ class GaussDBClient(Client):
|
|
9576
9994
|
|
9577
9995
|
return http_info
|
9578
9996
|
|
9579
|
-
def
|
9580
|
-
r"""
|
9997
|
+
def update_taurus_node_data_ip(self, request):
|
9998
|
+
r"""修改只读节点的读内网地址
|
9581
9999
|
|
9582
|
-
|
10000
|
+
修改只读节点的读内网地址。
|
9583
10001
|
|
9584
10002
|
Please refer to HUAWEI cloud API Explorer for details.
|
9585
10003
|
|
9586
|
-
:param request: Request instance for
|
9587
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.
|
9588
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.
|
10004
|
+
:param request: Request instance for UpdateTaurusNodeDataIp
|
10005
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.UpdateTaurusNodeDataIpRequest`
|
10006
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.UpdateTaurusNodeDataIpResponse`
|
9589
10007
|
"""
|
9590
|
-
http_info = self.
|
10008
|
+
http_info = self._update_taurus_node_data_ip_http_info(request)
|
9591
10009
|
return self._call_api(**http_info)
|
9592
10010
|
|
9593
|
-
def
|
9594
|
-
http_info = self.
|
10011
|
+
def update_taurus_node_data_ip_invoker(self, request):
|
10012
|
+
http_info = self._update_taurus_node_data_ip_http_info(request)
|
10013
|
+
return SyncInvoker(self, http_info)
|
10014
|
+
|
10015
|
+
@classmethod
|
10016
|
+
def _update_taurus_node_data_ip_http_info(cls, request):
|
10017
|
+
http_info = {
|
10018
|
+
"method": "PUT",
|
10019
|
+
"resource_path": "/v3/{project_id}/instances/{instance_id}/{node_id}/internal-ip",
|
10020
|
+
"request_type": request.__class__.__name__,
|
10021
|
+
"response_type": "UpdateTaurusNodeDataIpResponse"
|
10022
|
+
}
|
10023
|
+
|
10024
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
10025
|
+
|
10026
|
+
cname = None
|
10027
|
+
|
10028
|
+
collection_formats = {}
|
10029
|
+
|
10030
|
+
path_params = {}
|
10031
|
+
if 'instance_id' in local_var_params:
|
10032
|
+
path_params['instance_id'] = local_var_params['instance_id']
|
10033
|
+
if 'node_id' in local_var_params:
|
10034
|
+
path_params['node_id'] = local_var_params['node_id']
|
10035
|
+
|
10036
|
+
query_params = []
|
10037
|
+
|
10038
|
+
header_params = {}
|
10039
|
+
if 'x_language' in local_var_params:
|
10040
|
+
header_params['X-Language'] = local_var_params['x_language']
|
10041
|
+
|
10042
|
+
form_params = {}
|
10043
|
+
|
10044
|
+
body = None
|
10045
|
+
if 'body' in local_var_params:
|
10046
|
+
body = local_var_params['body']
|
10047
|
+
if isinstance(request, SdkStreamRequest):
|
10048
|
+
body = request.get_file_stream()
|
10049
|
+
|
10050
|
+
response_headers = []
|
10051
|
+
|
10052
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
10053
|
+
['application/json;charset=UTF-8'])
|
10054
|
+
|
10055
|
+
auth_settings = []
|
10056
|
+
|
10057
|
+
http_info["cname"] = cname
|
10058
|
+
http_info["collection_formats"] = collection_formats
|
10059
|
+
http_info["path_params"] = path_params
|
10060
|
+
http_info["query_params"] = query_params
|
10061
|
+
http_info["header_params"] = header_params
|
10062
|
+
http_info["post_params"] = form_params
|
10063
|
+
http_info["body"] = body
|
10064
|
+
http_info["response_headers"] = response_headers
|
10065
|
+
|
10066
|
+
return http_info
|
10067
|
+
|
10068
|
+
def update_transaction_split_status(self, request):
|
10069
|
+
r"""设置proxy事务拆分
|
10070
|
+
|
10071
|
+
设置proxy事务拆分。
|
10072
|
+
|
10073
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
10074
|
+
|
10075
|
+
:param request: Request instance for UpdateTransactionSplitStatus
|
10076
|
+
:type request: :class:`huaweicloudsdkgaussdb.v3.UpdateTransactionSplitStatusRequest`
|
10077
|
+
:rtype: :class:`huaweicloudsdkgaussdb.v3.UpdateTransactionSplitStatusResponse`
|
10078
|
+
"""
|
10079
|
+
http_info = self._update_transaction_split_status_http_info(request)
|
10080
|
+
return self._call_api(**http_info)
|
10081
|
+
|
10082
|
+
def update_transaction_split_status_invoker(self, request):
|
10083
|
+
http_info = self._update_transaction_split_status_http_info(request)
|
9595
10084
|
return SyncInvoker(self, http_info)
|
9596
10085
|
|
9597
10086
|
@classmethod
|
@@ -14008,351 +14497,6 @@ class GaussDBClient(Client):
|
|
14008
14497
|
|
14009
14498
|
return http_info
|
14010
14499
|
|
14011
|
-
def delete_sql_filter_rule(self, request):
|
14012
|
-
r"""删除SQL限流规则
|
14013
|
-
|
14014
|
-
删除SQL限流规则。
|
14015
|
-
|
14016
|
-
Please refer to HUAWEI cloud API Explorer for details.
|
14017
|
-
|
14018
|
-
:param request: Request instance for DeleteSqlFilterRule
|
14019
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.DeleteSqlFilterRuleRequest`
|
14020
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.DeleteSqlFilterRuleResponse`
|
14021
|
-
"""
|
14022
|
-
http_info = self._delete_sql_filter_rule_http_info(request)
|
14023
|
-
return self._call_api(**http_info)
|
14024
|
-
|
14025
|
-
def delete_sql_filter_rule_invoker(self, request):
|
14026
|
-
http_info = self._delete_sql_filter_rule_http_info(request)
|
14027
|
-
return SyncInvoker(self, http_info)
|
14028
|
-
|
14029
|
-
@classmethod
|
14030
|
-
def _delete_sql_filter_rule_http_info(cls, request):
|
14031
|
-
http_info = {
|
14032
|
-
"method": "DELETE",
|
14033
|
-
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/rules",
|
14034
|
-
"request_type": request.__class__.__name__,
|
14035
|
-
"response_type": "DeleteSqlFilterRuleResponse"
|
14036
|
-
}
|
14037
|
-
|
14038
|
-
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
14039
|
-
|
14040
|
-
cname = None
|
14041
|
-
|
14042
|
-
collection_formats = {}
|
14043
|
-
|
14044
|
-
path_params = {}
|
14045
|
-
if 'instance_id' in local_var_params:
|
14046
|
-
path_params['instance_id'] = local_var_params['instance_id']
|
14047
|
-
|
14048
|
-
query_params = []
|
14049
|
-
|
14050
|
-
header_params = {}
|
14051
|
-
if 'x_language' in local_var_params:
|
14052
|
-
header_params['X-Language'] = local_var_params['x_language']
|
14053
|
-
|
14054
|
-
form_params = {}
|
14055
|
-
|
14056
|
-
body = None
|
14057
|
-
if 'body' in local_var_params:
|
14058
|
-
body = local_var_params['body']
|
14059
|
-
if isinstance(request, SdkStreamRequest):
|
14060
|
-
body = request.get_file_stream()
|
14061
|
-
|
14062
|
-
response_headers = []
|
14063
|
-
|
14064
|
-
header_params['Content-Type'] = http_utils.select_header_content_type(
|
14065
|
-
['application/json;charset=UTF-8'])
|
14066
|
-
|
14067
|
-
auth_settings = []
|
14068
|
-
|
14069
|
-
http_info["cname"] = cname
|
14070
|
-
http_info["collection_formats"] = collection_formats
|
14071
|
-
http_info["path_params"] = path_params
|
14072
|
-
http_info["query_params"] = query_params
|
14073
|
-
http_info["header_params"] = header_params
|
14074
|
-
http_info["post_params"] = form_params
|
14075
|
-
http_info["body"] = body
|
14076
|
-
http_info["response_headers"] = response_headers
|
14077
|
-
|
14078
|
-
return http_info
|
14079
|
-
|
14080
|
-
def set_sql_filter_rule(self, request):
|
14081
|
-
r"""设置SQL限流规则
|
14082
|
-
|
14083
|
-
设置SQL限流规则。
|
14084
|
-
|
14085
|
-
Please refer to HUAWEI cloud API Explorer for details.
|
14086
|
-
|
14087
|
-
:param request: Request instance for SetSqlFilterRule
|
14088
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.SetSqlFilterRuleRequest`
|
14089
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.SetSqlFilterRuleResponse`
|
14090
|
-
"""
|
14091
|
-
http_info = self._set_sql_filter_rule_http_info(request)
|
14092
|
-
return self._call_api(**http_info)
|
14093
|
-
|
14094
|
-
def set_sql_filter_rule_invoker(self, request):
|
14095
|
-
http_info = self._set_sql_filter_rule_http_info(request)
|
14096
|
-
return SyncInvoker(self, http_info)
|
14097
|
-
|
14098
|
-
@classmethod
|
14099
|
-
def _set_sql_filter_rule_http_info(cls, request):
|
14100
|
-
http_info = {
|
14101
|
-
"method": "PUT",
|
14102
|
-
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/rules",
|
14103
|
-
"request_type": request.__class__.__name__,
|
14104
|
-
"response_type": "SetSqlFilterRuleResponse"
|
14105
|
-
}
|
14106
|
-
|
14107
|
-
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
14108
|
-
|
14109
|
-
cname = None
|
14110
|
-
|
14111
|
-
collection_formats = {}
|
14112
|
-
|
14113
|
-
path_params = {}
|
14114
|
-
if 'instance_id' in local_var_params:
|
14115
|
-
path_params['instance_id'] = local_var_params['instance_id']
|
14116
|
-
|
14117
|
-
query_params = []
|
14118
|
-
|
14119
|
-
header_params = {}
|
14120
|
-
if 'x_language' in local_var_params:
|
14121
|
-
header_params['X-Language'] = local_var_params['x_language']
|
14122
|
-
|
14123
|
-
form_params = {}
|
14124
|
-
|
14125
|
-
body = None
|
14126
|
-
if 'body' in local_var_params:
|
14127
|
-
body = local_var_params['body']
|
14128
|
-
if isinstance(request, SdkStreamRequest):
|
14129
|
-
body = request.get_file_stream()
|
14130
|
-
|
14131
|
-
response_headers = []
|
14132
|
-
|
14133
|
-
header_params['Content-Type'] = http_utils.select_header_content_type(
|
14134
|
-
['application/json;charset=UTF-8'])
|
14135
|
-
|
14136
|
-
auth_settings = []
|
14137
|
-
|
14138
|
-
http_info["cname"] = cname
|
14139
|
-
http_info["collection_formats"] = collection_formats
|
14140
|
-
http_info["path_params"] = path_params
|
14141
|
-
http_info["query_params"] = query_params
|
14142
|
-
http_info["header_params"] = header_params
|
14143
|
-
http_info["post_params"] = form_params
|
14144
|
-
http_info["body"] = body
|
14145
|
-
http_info["response_headers"] = response_headers
|
14146
|
-
|
14147
|
-
return http_info
|
14148
|
-
|
14149
|
-
def show_sql_filter_control(self, request):
|
14150
|
-
r"""查询SQL限流开关状态
|
14151
|
-
|
14152
|
-
查询SQL限流开关状态。
|
14153
|
-
|
14154
|
-
Please refer to HUAWEI cloud API Explorer for details.
|
14155
|
-
|
14156
|
-
:param request: Request instance for ShowSqlFilterControl
|
14157
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterControlRequest`
|
14158
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterControlResponse`
|
14159
|
-
"""
|
14160
|
-
http_info = self._show_sql_filter_control_http_info(request)
|
14161
|
-
return self._call_api(**http_info)
|
14162
|
-
|
14163
|
-
def show_sql_filter_control_invoker(self, request):
|
14164
|
-
http_info = self._show_sql_filter_control_http_info(request)
|
14165
|
-
return SyncInvoker(self, http_info)
|
14166
|
-
|
14167
|
-
@classmethod
|
14168
|
-
def _show_sql_filter_control_http_info(cls, request):
|
14169
|
-
http_info = {
|
14170
|
-
"method": "GET",
|
14171
|
-
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/switch",
|
14172
|
-
"request_type": request.__class__.__name__,
|
14173
|
-
"response_type": "ShowSqlFilterControlResponse"
|
14174
|
-
}
|
14175
|
-
|
14176
|
-
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
14177
|
-
|
14178
|
-
cname = None
|
14179
|
-
|
14180
|
-
collection_formats = {}
|
14181
|
-
|
14182
|
-
path_params = {}
|
14183
|
-
if 'instance_id' in local_var_params:
|
14184
|
-
path_params['instance_id'] = local_var_params['instance_id']
|
14185
|
-
|
14186
|
-
query_params = []
|
14187
|
-
|
14188
|
-
header_params = {}
|
14189
|
-
if 'x_language' in local_var_params:
|
14190
|
-
header_params['X-Language'] = local_var_params['x_language']
|
14191
|
-
|
14192
|
-
form_params = {}
|
14193
|
-
|
14194
|
-
body = None
|
14195
|
-
if isinstance(request, SdkStreamRequest):
|
14196
|
-
body = request.get_file_stream()
|
14197
|
-
|
14198
|
-
response_headers = []
|
14199
|
-
|
14200
|
-
header_params['Content-Type'] = http_utils.select_header_content_type(
|
14201
|
-
['application/json'])
|
14202
|
-
|
14203
|
-
auth_settings = []
|
14204
|
-
|
14205
|
-
http_info["cname"] = cname
|
14206
|
-
http_info["collection_formats"] = collection_formats
|
14207
|
-
http_info["path_params"] = path_params
|
14208
|
-
http_info["query_params"] = query_params
|
14209
|
-
http_info["header_params"] = header_params
|
14210
|
-
http_info["post_params"] = form_params
|
14211
|
-
http_info["body"] = body
|
14212
|
-
http_info["response_headers"] = response_headers
|
14213
|
-
|
14214
|
-
return http_info
|
14215
|
-
|
14216
|
-
def show_sql_filter_rule(self, request):
|
14217
|
-
r"""查询SQL限流规则
|
14218
|
-
|
14219
|
-
查询SQL限流规则。
|
14220
|
-
|
14221
|
-
Please refer to HUAWEI cloud API Explorer for details.
|
14222
|
-
|
14223
|
-
:param request: Request instance for ShowSqlFilterRule
|
14224
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterRuleRequest`
|
14225
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.ShowSqlFilterRuleResponse`
|
14226
|
-
"""
|
14227
|
-
http_info = self._show_sql_filter_rule_http_info(request)
|
14228
|
-
return self._call_api(**http_info)
|
14229
|
-
|
14230
|
-
def show_sql_filter_rule_invoker(self, request):
|
14231
|
-
http_info = self._show_sql_filter_rule_http_info(request)
|
14232
|
-
return SyncInvoker(self, http_info)
|
14233
|
-
|
14234
|
-
@classmethod
|
14235
|
-
def _show_sql_filter_rule_http_info(cls, request):
|
14236
|
-
http_info = {
|
14237
|
-
"method": "GET",
|
14238
|
-
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/rules",
|
14239
|
-
"request_type": request.__class__.__name__,
|
14240
|
-
"response_type": "ShowSqlFilterRuleResponse"
|
14241
|
-
}
|
14242
|
-
|
14243
|
-
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
14244
|
-
|
14245
|
-
cname = None
|
14246
|
-
|
14247
|
-
collection_formats = {}
|
14248
|
-
|
14249
|
-
path_params = {}
|
14250
|
-
if 'instance_id' in local_var_params:
|
14251
|
-
path_params['instance_id'] = local_var_params['instance_id']
|
14252
|
-
|
14253
|
-
query_params = []
|
14254
|
-
if 'node_id' in local_var_params:
|
14255
|
-
query_params.append(('node_id', local_var_params['node_id']))
|
14256
|
-
if 'sql_type' in local_var_params:
|
14257
|
-
query_params.append(('sql_type', local_var_params['sql_type']))
|
14258
|
-
|
14259
|
-
header_params = {}
|
14260
|
-
if 'x_language' in local_var_params:
|
14261
|
-
header_params['X-Language'] = local_var_params['x_language']
|
14262
|
-
|
14263
|
-
form_params = {}
|
14264
|
-
|
14265
|
-
body = None
|
14266
|
-
if isinstance(request, SdkStreamRequest):
|
14267
|
-
body = request.get_file_stream()
|
14268
|
-
|
14269
|
-
response_headers = []
|
14270
|
-
|
14271
|
-
header_params['Content-Type'] = http_utils.select_header_content_type(
|
14272
|
-
['application/json'])
|
14273
|
-
|
14274
|
-
auth_settings = []
|
14275
|
-
|
14276
|
-
http_info["cname"] = cname
|
14277
|
-
http_info["collection_formats"] = collection_formats
|
14278
|
-
http_info["path_params"] = path_params
|
14279
|
-
http_info["query_params"] = query_params
|
14280
|
-
http_info["header_params"] = header_params
|
14281
|
-
http_info["post_params"] = form_params
|
14282
|
-
http_info["body"] = body
|
14283
|
-
http_info["response_headers"] = response_headers
|
14284
|
-
|
14285
|
-
return http_info
|
14286
|
-
|
14287
|
-
def update_sql_filter_control(self, request):
|
14288
|
-
r"""开启或者关闭SQL限流
|
14289
|
-
|
14290
|
-
开启或者关闭SQL限流。
|
14291
|
-
|
14292
|
-
Please refer to HUAWEI cloud API Explorer for details.
|
14293
|
-
|
14294
|
-
:param request: Request instance for UpdateSqlFilterControl
|
14295
|
-
:type request: :class:`huaweicloudsdkgaussdb.v3.UpdateSqlFilterControlRequest`
|
14296
|
-
:rtype: :class:`huaweicloudsdkgaussdb.v3.UpdateSqlFilterControlResponse`
|
14297
|
-
"""
|
14298
|
-
http_info = self._update_sql_filter_control_http_info(request)
|
14299
|
-
return self._call_api(**http_info)
|
14300
|
-
|
14301
|
-
def update_sql_filter_control_invoker(self, request):
|
14302
|
-
http_info = self._update_sql_filter_control_http_info(request)
|
14303
|
-
return SyncInvoker(self, http_info)
|
14304
|
-
|
14305
|
-
@classmethod
|
14306
|
-
def _update_sql_filter_control_http_info(cls, request):
|
14307
|
-
http_info = {
|
14308
|
-
"method": "POST",
|
14309
|
-
"resource_path": "/v3/{project_id}/instances/{instance_id}/sql-filter/switch",
|
14310
|
-
"request_type": request.__class__.__name__,
|
14311
|
-
"response_type": "UpdateSqlFilterControlResponse"
|
14312
|
-
}
|
14313
|
-
|
14314
|
-
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
14315
|
-
|
14316
|
-
cname = None
|
14317
|
-
|
14318
|
-
collection_formats = {}
|
14319
|
-
|
14320
|
-
path_params = {}
|
14321
|
-
if 'instance_id' in local_var_params:
|
14322
|
-
path_params['instance_id'] = local_var_params['instance_id']
|
14323
|
-
|
14324
|
-
query_params = []
|
14325
|
-
|
14326
|
-
header_params = {}
|
14327
|
-
if 'x_language' in local_var_params:
|
14328
|
-
header_params['X-Language'] = local_var_params['x_language']
|
14329
|
-
|
14330
|
-
form_params = {}
|
14331
|
-
|
14332
|
-
body = None
|
14333
|
-
if 'body' in local_var_params:
|
14334
|
-
body = local_var_params['body']
|
14335
|
-
if isinstance(request, SdkStreamRequest):
|
14336
|
-
body = request.get_file_stream()
|
14337
|
-
|
14338
|
-
response_headers = []
|
14339
|
-
|
14340
|
-
header_params['Content-Type'] = http_utils.select_header_content_type(
|
14341
|
-
['application/json;charset=UTF-8'])
|
14342
|
-
|
14343
|
-
auth_settings = []
|
14344
|
-
|
14345
|
-
http_info["cname"] = cname
|
14346
|
-
http_info["collection_formats"] = collection_formats
|
14347
|
-
http_info["path_params"] = path_params
|
14348
|
-
http_info["query_params"] = query_params
|
14349
|
-
http_info["header_params"] = header_params
|
14350
|
-
http_info["post_params"] = form_params
|
14351
|
-
http_info["body"] = body
|
14352
|
-
http_info["response_headers"] = response_headers
|
14353
|
-
|
14354
|
-
return http_info
|
14355
|
-
|
14356
14500
|
def _call_api(self, **kwargs):
|
14357
14501
|
try:
|
14358
14502
|
return self.do_http_request(**kwargs)
|