alibabacloud-fc20230330 4.2.7__py3-none-any.whl → 4.5.0__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.
- alibabacloud_fc20230330/__init__.py +1 -1
- alibabacloud_fc20230330/client.py +536 -0
- alibabacloud_fc20230330/models.py +1563 -54
- {alibabacloud_fc20230330-4.2.7.dist-info → alibabacloud_fc20230330-4.5.0.dist-info}/METADATA +2 -2
- alibabacloud_fc20230330-4.5.0.dist-info/RECORD +8 -0
- alibabacloud_fc20230330-4.2.7.dist-info/RECORD +0 -8
- {alibabacloud_fc20230330-4.2.7.dist-info → alibabacloud_fc20230330-4.5.0.dist-info}/LICENSE +0 -0
- {alibabacloud_fc20230330-4.2.7.dist-info → alibabacloud_fc20230330-4.5.0.dist-info}/WHEEL +0 -0
- {alibabacloud_fc20230330-4.2.7.dist-info → alibabacloud_fc20230330-4.5.0.dist-info}/top_level.txt +0 -0
@@ -1 +1 @@
|
|
1
|
-
__version__ = '4.
|
1
|
+
__version__ = '4.5.0'
|
@@ -41,6 +41,104 @@ class Client(OpenApiClient):
|
|
41
41
|
return endpoint_map.get(region_id)
|
42
42
|
return EndpointUtilClient.get_endpoint_rules(product_id, region_id, endpoint_rule, network, suffix)
|
43
43
|
|
44
|
+
def change_resource_group_with_options(
|
45
|
+
self,
|
46
|
+
request: fc20230330_models.ChangeResourceGroupRequest,
|
47
|
+
headers: Dict[str, str],
|
48
|
+
runtime: util_models.RuntimeOptions,
|
49
|
+
) -> fc20230330_models.ChangeResourceGroupResponse:
|
50
|
+
"""
|
51
|
+
@summary 修改实例所在资源组
|
52
|
+
|
53
|
+
@param request: ChangeResourceGroupRequest
|
54
|
+
@param headers: map
|
55
|
+
@param runtime: runtime options for this request RuntimeOptions
|
56
|
+
@return: ChangeResourceGroupResponse
|
57
|
+
"""
|
58
|
+
UtilClient.validate_model(request)
|
59
|
+
req = open_api_models.OpenApiRequest(
|
60
|
+
headers=headers,
|
61
|
+
body=OpenApiUtilClient.parse_to_map(request.body)
|
62
|
+
)
|
63
|
+
params = open_api_models.Params(
|
64
|
+
action='ChangeResourceGroup',
|
65
|
+
version='2023-03-30',
|
66
|
+
protocol='HTTPS',
|
67
|
+
pathname=f'/2023-03-30/resource-groups',
|
68
|
+
method='PUT',
|
69
|
+
auth_type='AK',
|
70
|
+
style='ROA',
|
71
|
+
req_body_type='json',
|
72
|
+
body_type='json'
|
73
|
+
)
|
74
|
+
return TeaCore.from_map(
|
75
|
+
fc20230330_models.ChangeResourceGroupResponse(),
|
76
|
+
self.call_api(params, req, runtime)
|
77
|
+
)
|
78
|
+
|
79
|
+
async def change_resource_group_with_options_async(
|
80
|
+
self,
|
81
|
+
request: fc20230330_models.ChangeResourceGroupRequest,
|
82
|
+
headers: Dict[str, str],
|
83
|
+
runtime: util_models.RuntimeOptions,
|
84
|
+
) -> fc20230330_models.ChangeResourceGroupResponse:
|
85
|
+
"""
|
86
|
+
@summary 修改实例所在资源组
|
87
|
+
|
88
|
+
@param request: ChangeResourceGroupRequest
|
89
|
+
@param headers: map
|
90
|
+
@param runtime: runtime options for this request RuntimeOptions
|
91
|
+
@return: ChangeResourceGroupResponse
|
92
|
+
"""
|
93
|
+
UtilClient.validate_model(request)
|
94
|
+
req = open_api_models.OpenApiRequest(
|
95
|
+
headers=headers,
|
96
|
+
body=OpenApiUtilClient.parse_to_map(request.body)
|
97
|
+
)
|
98
|
+
params = open_api_models.Params(
|
99
|
+
action='ChangeResourceGroup',
|
100
|
+
version='2023-03-30',
|
101
|
+
protocol='HTTPS',
|
102
|
+
pathname=f'/2023-03-30/resource-groups',
|
103
|
+
method='PUT',
|
104
|
+
auth_type='AK',
|
105
|
+
style='ROA',
|
106
|
+
req_body_type='json',
|
107
|
+
body_type='json'
|
108
|
+
)
|
109
|
+
return TeaCore.from_map(
|
110
|
+
fc20230330_models.ChangeResourceGroupResponse(),
|
111
|
+
await self.call_api_async(params, req, runtime)
|
112
|
+
)
|
113
|
+
|
114
|
+
def change_resource_group(
|
115
|
+
self,
|
116
|
+
request: fc20230330_models.ChangeResourceGroupRequest,
|
117
|
+
) -> fc20230330_models.ChangeResourceGroupResponse:
|
118
|
+
"""
|
119
|
+
@summary 修改实例所在资源组
|
120
|
+
|
121
|
+
@param request: ChangeResourceGroupRequest
|
122
|
+
@return: ChangeResourceGroupResponse
|
123
|
+
"""
|
124
|
+
runtime = util_models.RuntimeOptions()
|
125
|
+
headers = {}
|
126
|
+
return self.change_resource_group_with_options(request, headers, runtime)
|
127
|
+
|
128
|
+
async def change_resource_group_async(
|
129
|
+
self,
|
130
|
+
request: fc20230330_models.ChangeResourceGroupRequest,
|
131
|
+
) -> fc20230330_models.ChangeResourceGroupResponse:
|
132
|
+
"""
|
133
|
+
@summary 修改实例所在资源组
|
134
|
+
|
135
|
+
@param request: ChangeResourceGroupRequest
|
136
|
+
@return: ChangeResourceGroupResponse
|
137
|
+
"""
|
138
|
+
runtime = util_models.RuntimeOptions()
|
139
|
+
headers = {}
|
140
|
+
return await self.change_resource_group_with_options_async(request, headers, runtime)
|
141
|
+
|
44
142
|
def create_alias_with_options(
|
45
143
|
self,
|
46
144
|
function_name: str,
|
@@ -1429,6 +1527,114 @@ class Client(OpenApiClient):
|
|
1429
1527
|
headers = {}
|
1430
1528
|
return await self.delete_provision_config_with_options_async(function_name, request, headers, runtime)
|
1431
1529
|
|
1530
|
+
def delete_scaling_config_with_options(
|
1531
|
+
self,
|
1532
|
+
function_name: str,
|
1533
|
+
request: fc20230330_models.DeleteScalingConfigRequest,
|
1534
|
+
headers: Dict[str, str],
|
1535
|
+
runtime: util_models.RuntimeOptions,
|
1536
|
+
) -> fc20230330_models.DeleteScalingConfigResponse:
|
1537
|
+
"""
|
1538
|
+
@summary 删除弹性配置
|
1539
|
+
|
1540
|
+
@param request: DeleteScalingConfigRequest
|
1541
|
+
@param headers: map
|
1542
|
+
@param runtime: runtime options for this request RuntimeOptions
|
1543
|
+
@return: DeleteScalingConfigResponse
|
1544
|
+
"""
|
1545
|
+
UtilClient.validate_model(request)
|
1546
|
+
query = {}
|
1547
|
+
if not UtilClient.is_unset(request.qualifier):
|
1548
|
+
query['qualifier'] = request.qualifier
|
1549
|
+
req = open_api_models.OpenApiRequest(
|
1550
|
+
headers=headers,
|
1551
|
+
query=OpenApiUtilClient.query(query)
|
1552
|
+
)
|
1553
|
+
params = open_api_models.Params(
|
1554
|
+
action='DeleteScalingConfig',
|
1555
|
+
version='2023-03-30',
|
1556
|
+
protocol='HTTPS',
|
1557
|
+
pathname=f'/2023-03-30/functions/{OpenApiUtilClient.get_encode_param(function_name)}/scaling-config',
|
1558
|
+
method='DELETE',
|
1559
|
+
auth_type='AK',
|
1560
|
+
style='ROA',
|
1561
|
+
req_body_type='json',
|
1562
|
+
body_type='none'
|
1563
|
+
)
|
1564
|
+
return TeaCore.from_map(
|
1565
|
+
fc20230330_models.DeleteScalingConfigResponse(),
|
1566
|
+
self.call_api(params, req, runtime)
|
1567
|
+
)
|
1568
|
+
|
1569
|
+
async def delete_scaling_config_with_options_async(
|
1570
|
+
self,
|
1571
|
+
function_name: str,
|
1572
|
+
request: fc20230330_models.DeleteScalingConfigRequest,
|
1573
|
+
headers: Dict[str, str],
|
1574
|
+
runtime: util_models.RuntimeOptions,
|
1575
|
+
) -> fc20230330_models.DeleteScalingConfigResponse:
|
1576
|
+
"""
|
1577
|
+
@summary 删除弹性配置
|
1578
|
+
|
1579
|
+
@param request: DeleteScalingConfigRequest
|
1580
|
+
@param headers: map
|
1581
|
+
@param runtime: runtime options for this request RuntimeOptions
|
1582
|
+
@return: DeleteScalingConfigResponse
|
1583
|
+
"""
|
1584
|
+
UtilClient.validate_model(request)
|
1585
|
+
query = {}
|
1586
|
+
if not UtilClient.is_unset(request.qualifier):
|
1587
|
+
query['qualifier'] = request.qualifier
|
1588
|
+
req = open_api_models.OpenApiRequest(
|
1589
|
+
headers=headers,
|
1590
|
+
query=OpenApiUtilClient.query(query)
|
1591
|
+
)
|
1592
|
+
params = open_api_models.Params(
|
1593
|
+
action='DeleteScalingConfig',
|
1594
|
+
version='2023-03-30',
|
1595
|
+
protocol='HTTPS',
|
1596
|
+
pathname=f'/2023-03-30/functions/{OpenApiUtilClient.get_encode_param(function_name)}/scaling-config',
|
1597
|
+
method='DELETE',
|
1598
|
+
auth_type='AK',
|
1599
|
+
style='ROA',
|
1600
|
+
req_body_type='json',
|
1601
|
+
body_type='none'
|
1602
|
+
)
|
1603
|
+
return TeaCore.from_map(
|
1604
|
+
fc20230330_models.DeleteScalingConfigResponse(),
|
1605
|
+
await self.call_api_async(params, req, runtime)
|
1606
|
+
)
|
1607
|
+
|
1608
|
+
def delete_scaling_config(
|
1609
|
+
self,
|
1610
|
+
function_name: str,
|
1611
|
+
request: fc20230330_models.DeleteScalingConfigRequest,
|
1612
|
+
) -> fc20230330_models.DeleteScalingConfigResponse:
|
1613
|
+
"""
|
1614
|
+
@summary 删除弹性配置
|
1615
|
+
|
1616
|
+
@param request: DeleteScalingConfigRequest
|
1617
|
+
@return: DeleteScalingConfigResponse
|
1618
|
+
"""
|
1619
|
+
runtime = util_models.RuntimeOptions()
|
1620
|
+
headers = {}
|
1621
|
+
return self.delete_scaling_config_with_options(function_name, request, headers, runtime)
|
1622
|
+
|
1623
|
+
async def delete_scaling_config_async(
|
1624
|
+
self,
|
1625
|
+
function_name: str,
|
1626
|
+
request: fc20230330_models.DeleteScalingConfigRequest,
|
1627
|
+
) -> fc20230330_models.DeleteScalingConfigResponse:
|
1628
|
+
"""
|
1629
|
+
@summary 删除弹性配置
|
1630
|
+
|
1631
|
+
@param request: DeleteScalingConfigRequest
|
1632
|
+
@return: DeleteScalingConfigResponse
|
1633
|
+
"""
|
1634
|
+
runtime = util_models.RuntimeOptions()
|
1635
|
+
headers = {}
|
1636
|
+
return await self.delete_scaling_config_with_options_async(function_name, request, headers, runtime)
|
1637
|
+
|
1432
1638
|
def delete_trigger_with_options(
|
1433
1639
|
self,
|
1434
1640
|
function_name: str,
|
@@ -2933,6 +3139,114 @@ class Client(OpenApiClient):
|
|
2933
3139
|
headers = {}
|
2934
3140
|
return await self.get_provision_config_with_options_async(function_name, request, headers, runtime)
|
2935
3141
|
|
3142
|
+
def get_scaling_config_with_options(
|
3143
|
+
self,
|
3144
|
+
function_name: str,
|
3145
|
+
request: fc20230330_models.GetScalingConfigRequest,
|
3146
|
+
headers: Dict[str, str],
|
3147
|
+
runtime: util_models.RuntimeOptions,
|
3148
|
+
) -> fc20230330_models.GetScalingConfigResponse:
|
3149
|
+
"""
|
3150
|
+
@summary 获取弹性配置
|
3151
|
+
|
3152
|
+
@param request: GetScalingConfigRequest
|
3153
|
+
@param headers: map
|
3154
|
+
@param runtime: runtime options for this request RuntimeOptions
|
3155
|
+
@return: GetScalingConfigResponse
|
3156
|
+
"""
|
3157
|
+
UtilClient.validate_model(request)
|
3158
|
+
query = {}
|
3159
|
+
if not UtilClient.is_unset(request.qualifier):
|
3160
|
+
query['qualifier'] = request.qualifier
|
3161
|
+
req = open_api_models.OpenApiRequest(
|
3162
|
+
headers=headers,
|
3163
|
+
query=OpenApiUtilClient.query(query)
|
3164
|
+
)
|
3165
|
+
params = open_api_models.Params(
|
3166
|
+
action='GetScalingConfig',
|
3167
|
+
version='2023-03-30',
|
3168
|
+
protocol='HTTPS',
|
3169
|
+
pathname=f'/2023-03-30/functions/{OpenApiUtilClient.get_encode_param(function_name)}/scaling-config',
|
3170
|
+
method='GET',
|
3171
|
+
auth_type='AK',
|
3172
|
+
style='ROA',
|
3173
|
+
req_body_type='json',
|
3174
|
+
body_type='json'
|
3175
|
+
)
|
3176
|
+
return TeaCore.from_map(
|
3177
|
+
fc20230330_models.GetScalingConfigResponse(),
|
3178
|
+
self.call_api(params, req, runtime)
|
3179
|
+
)
|
3180
|
+
|
3181
|
+
async def get_scaling_config_with_options_async(
|
3182
|
+
self,
|
3183
|
+
function_name: str,
|
3184
|
+
request: fc20230330_models.GetScalingConfigRequest,
|
3185
|
+
headers: Dict[str, str],
|
3186
|
+
runtime: util_models.RuntimeOptions,
|
3187
|
+
) -> fc20230330_models.GetScalingConfigResponse:
|
3188
|
+
"""
|
3189
|
+
@summary 获取弹性配置
|
3190
|
+
|
3191
|
+
@param request: GetScalingConfigRequest
|
3192
|
+
@param headers: map
|
3193
|
+
@param runtime: runtime options for this request RuntimeOptions
|
3194
|
+
@return: GetScalingConfigResponse
|
3195
|
+
"""
|
3196
|
+
UtilClient.validate_model(request)
|
3197
|
+
query = {}
|
3198
|
+
if not UtilClient.is_unset(request.qualifier):
|
3199
|
+
query['qualifier'] = request.qualifier
|
3200
|
+
req = open_api_models.OpenApiRequest(
|
3201
|
+
headers=headers,
|
3202
|
+
query=OpenApiUtilClient.query(query)
|
3203
|
+
)
|
3204
|
+
params = open_api_models.Params(
|
3205
|
+
action='GetScalingConfig',
|
3206
|
+
version='2023-03-30',
|
3207
|
+
protocol='HTTPS',
|
3208
|
+
pathname=f'/2023-03-30/functions/{OpenApiUtilClient.get_encode_param(function_name)}/scaling-config',
|
3209
|
+
method='GET',
|
3210
|
+
auth_type='AK',
|
3211
|
+
style='ROA',
|
3212
|
+
req_body_type='json',
|
3213
|
+
body_type='json'
|
3214
|
+
)
|
3215
|
+
return TeaCore.from_map(
|
3216
|
+
fc20230330_models.GetScalingConfigResponse(),
|
3217
|
+
await self.call_api_async(params, req, runtime)
|
3218
|
+
)
|
3219
|
+
|
3220
|
+
def get_scaling_config(
|
3221
|
+
self,
|
3222
|
+
function_name: str,
|
3223
|
+
request: fc20230330_models.GetScalingConfigRequest,
|
3224
|
+
) -> fc20230330_models.GetScalingConfigResponse:
|
3225
|
+
"""
|
3226
|
+
@summary 获取弹性配置
|
3227
|
+
|
3228
|
+
@param request: GetScalingConfigRequest
|
3229
|
+
@return: GetScalingConfigResponse
|
3230
|
+
"""
|
3231
|
+
runtime = util_models.RuntimeOptions()
|
3232
|
+
headers = {}
|
3233
|
+
return self.get_scaling_config_with_options(function_name, request, headers, runtime)
|
3234
|
+
|
3235
|
+
async def get_scaling_config_async(
|
3236
|
+
self,
|
3237
|
+
function_name: str,
|
3238
|
+
request: fc20230330_models.GetScalingConfigRequest,
|
3239
|
+
) -> fc20230330_models.GetScalingConfigResponse:
|
3240
|
+
"""
|
3241
|
+
@summary 获取弹性配置
|
3242
|
+
|
3243
|
+
@param request: GetScalingConfigRequest
|
3244
|
+
@return: GetScalingConfigResponse
|
3245
|
+
"""
|
3246
|
+
runtime = util_models.RuntimeOptions()
|
3247
|
+
headers = {}
|
3248
|
+
return await self.get_scaling_config_with_options_async(function_name, request, headers, runtime)
|
3249
|
+
|
2936
3250
|
def get_trigger_with_options(
|
2937
3251
|
self,
|
2938
3252
|
function_name: str,
|
@@ -4529,6 +4843,118 @@ class Client(OpenApiClient):
|
|
4529
4843
|
headers = {}
|
4530
4844
|
return await self.list_provision_configs_with_options_async(request, headers, runtime)
|
4531
4845
|
|
4846
|
+
def list_scaling_configs_with_options(
|
4847
|
+
self,
|
4848
|
+
request: fc20230330_models.ListScalingConfigsRequest,
|
4849
|
+
headers: Dict[str, str],
|
4850
|
+
runtime: util_models.RuntimeOptions,
|
4851
|
+
) -> fc20230330_models.ListScalingConfigsResponse:
|
4852
|
+
"""
|
4853
|
+
@summary 获取弹性配置列表
|
4854
|
+
|
4855
|
+
@param request: ListScalingConfigsRequest
|
4856
|
+
@param headers: map
|
4857
|
+
@param runtime: runtime options for this request RuntimeOptions
|
4858
|
+
@return: ListScalingConfigsResponse
|
4859
|
+
"""
|
4860
|
+
UtilClient.validate_model(request)
|
4861
|
+
query = {}
|
4862
|
+
if not UtilClient.is_unset(request.function_name):
|
4863
|
+
query['functionName'] = request.function_name
|
4864
|
+
if not UtilClient.is_unset(request.limit):
|
4865
|
+
query['limit'] = request.limit
|
4866
|
+
if not UtilClient.is_unset(request.next_token):
|
4867
|
+
query['nextToken'] = request.next_token
|
4868
|
+
req = open_api_models.OpenApiRequest(
|
4869
|
+
headers=headers,
|
4870
|
+
query=OpenApiUtilClient.query(query)
|
4871
|
+
)
|
4872
|
+
params = open_api_models.Params(
|
4873
|
+
action='ListScalingConfigs',
|
4874
|
+
version='2023-03-30',
|
4875
|
+
protocol='HTTPS',
|
4876
|
+
pathname=f'/2023-03-30/scaling-configs',
|
4877
|
+
method='GET',
|
4878
|
+
auth_type='AK',
|
4879
|
+
style='ROA',
|
4880
|
+
req_body_type='json',
|
4881
|
+
body_type='json'
|
4882
|
+
)
|
4883
|
+
return TeaCore.from_map(
|
4884
|
+
fc20230330_models.ListScalingConfigsResponse(),
|
4885
|
+
self.call_api(params, req, runtime)
|
4886
|
+
)
|
4887
|
+
|
4888
|
+
async def list_scaling_configs_with_options_async(
|
4889
|
+
self,
|
4890
|
+
request: fc20230330_models.ListScalingConfigsRequest,
|
4891
|
+
headers: Dict[str, str],
|
4892
|
+
runtime: util_models.RuntimeOptions,
|
4893
|
+
) -> fc20230330_models.ListScalingConfigsResponse:
|
4894
|
+
"""
|
4895
|
+
@summary 获取弹性配置列表
|
4896
|
+
|
4897
|
+
@param request: ListScalingConfigsRequest
|
4898
|
+
@param headers: map
|
4899
|
+
@param runtime: runtime options for this request RuntimeOptions
|
4900
|
+
@return: ListScalingConfigsResponse
|
4901
|
+
"""
|
4902
|
+
UtilClient.validate_model(request)
|
4903
|
+
query = {}
|
4904
|
+
if not UtilClient.is_unset(request.function_name):
|
4905
|
+
query['functionName'] = request.function_name
|
4906
|
+
if not UtilClient.is_unset(request.limit):
|
4907
|
+
query['limit'] = request.limit
|
4908
|
+
if not UtilClient.is_unset(request.next_token):
|
4909
|
+
query['nextToken'] = request.next_token
|
4910
|
+
req = open_api_models.OpenApiRequest(
|
4911
|
+
headers=headers,
|
4912
|
+
query=OpenApiUtilClient.query(query)
|
4913
|
+
)
|
4914
|
+
params = open_api_models.Params(
|
4915
|
+
action='ListScalingConfigs',
|
4916
|
+
version='2023-03-30',
|
4917
|
+
protocol='HTTPS',
|
4918
|
+
pathname=f'/2023-03-30/scaling-configs',
|
4919
|
+
method='GET',
|
4920
|
+
auth_type='AK',
|
4921
|
+
style='ROA',
|
4922
|
+
req_body_type='json',
|
4923
|
+
body_type='json'
|
4924
|
+
)
|
4925
|
+
return TeaCore.from_map(
|
4926
|
+
fc20230330_models.ListScalingConfigsResponse(),
|
4927
|
+
await self.call_api_async(params, req, runtime)
|
4928
|
+
)
|
4929
|
+
|
4930
|
+
def list_scaling_configs(
|
4931
|
+
self,
|
4932
|
+
request: fc20230330_models.ListScalingConfigsRequest,
|
4933
|
+
) -> fc20230330_models.ListScalingConfigsResponse:
|
4934
|
+
"""
|
4935
|
+
@summary 获取弹性配置列表
|
4936
|
+
|
4937
|
+
@param request: ListScalingConfigsRequest
|
4938
|
+
@return: ListScalingConfigsResponse
|
4939
|
+
"""
|
4940
|
+
runtime = util_models.RuntimeOptions()
|
4941
|
+
headers = {}
|
4942
|
+
return self.list_scaling_configs_with_options(request, headers, runtime)
|
4943
|
+
|
4944
|
+
async def list_scaling_configs_async(
|
4945
|
+
self,
|
4946
|
+
request: fc20230330_models.ListScalingConfigsRequest,
|
4947
|
+
) -> fc20230330_models.ListScalingConfigsResponse:
|
4948
|
+
"""
|
4949
|
+
@summary 获取弹性配置列表
|
4950
|
+
|
4951
|
+
@param request: ListScalingConfigsRequest
|
4952
|
+
@return: ListScalingConfigsResponse
|
4953
|
+
"""
|
4954
|
+
runtime = util_models.RuntimeOptions()
|
4955
|
+
headers = {}
|
4956
|
+
return await self.list_scaling_configs_with_options_async(request, headers, runtime)
|
4957
|
+
|
4532
4958
|
def list_tag_resources_with_options(
|
4533
4959
|
self,
|
4534
4960
|
tmp_req: fc20230330_models.ListTagResourcesRequest,
|
@@ -5403,6 +5829,116 @@ class Client(OpenApiClient):
|
|
5403
5829
|
headers = {}
|
5404
5830
|
return await self.put_provision_config_with_options_async(function_name, request, headers, runtime)
|
5405
5831
|
|
5832
|
+
def put_scaling_config_with_options(
|
5833
|
+
self,
|
5834
|
+
function_name: str,
|
5835
|
+
request: fc20230330_models.PutScalingConfigRequest,
|
5836
|
+
headers: Dict[str, str],
|
5837
|
+
runtime: util_models.RuntimeOptions,
|
5838
|
+
) -> fc20230330_models.PutScalingConfigResponse:
|
5839
|
+
"""
|
5840
|
+
@summary 设置弹性配置
|
5841
|
+
|
5842
|
+
@param request: PutScalingConfigRequest
|
5843
|
+
@param headers: map
|
5844
|
+
@param runtime: runtime options for this request RuntimeOptions
|
5845
|
+
@return: PutScalingConfigResponse
|
5846
|
+
"""
|
5847
|
+
UtilClient.validate_model(request)
|
5848
|
+
query = {}
|
5849
|
+
if not UtilClient.is_unset(request.qualifier):
|
5850
|
+
query['qualifier'] = request.qualifier
|
5851
|
+
req = open_api_models.OpenApiRequest(
|
5852
|
+
headers=headers,
|
5853
|
+
query=OpenApiUtilClient.query(query),
|
5854
|
+
body=OpenApiUtilClient.parse_to_map(request.body)
|
5855
|
+
)
|
5856
|
+
params = open_api_models.Params(
|
5857
|
+
action='PutScalingConfig',
|
5858
|
+
version='2023-03-30',
|
5859
|
+
protocol='HTTPS',
|
5860
|
+
pathname=f'/2023-03-30/functions/{OpenApiUtilClient.get_encode_param(function_name)}/scaling-config',
|
5861
|
+
method='PUT',
|
5862
|
+
auth_type='AK',
|
5863
|
+
style='ROA',
|
5864
|
+
req_body_type='json',
|
5865
|
+
body_type='json'
|
5866
|
+
)
|
5867
|
+
return TeaCore.from_map(
|
5868
|
+
fc20230330_models.PutScalingConfigResponse(),
|
5869
|
+
self.call_api(params, req, runtime)
|
5870
|
+
)
|
5871
|
+
|
5872
|
+
async def put_scaling_config_with_options_async(
|
5873
|
+
self,
|
5874
|
+
function_name: str,
|
5875
|
+
request: fc20230330_models.PutScalingConfigRequest,
|
5876
|
+
headers: Dict[str, str],
|
5877
|
+
runtime: util_models.RuntimeOptions,
|
5878
|
+
) -> fc20230330_models.PutScalingConfigResponse:
|
5879
|
+
"""
|
5880
|
+
@summary 设置弹性配置
|
5881
|
+
|
5882
|
+
@param request: PutScalingConfigRequest
|
5883
|
+
@param headers: map
|
5884
|
+
@param runtime: runtime options for this request RuntimeOptions
|
5885
|
+
@return: PutScalingConfigResponse
|
5886
|
+
"""
|
5887
|
+
UtilClient.validate_model(request)
|
5888
|
+
query = {}
|
5889
|
+
if not UtilClient.is_unset(request.qualifier):
|
5890
|
+
query['qualifier'] = request.qualifier
|
5891
|
+
req = open_api_models.OpenApiRequest(
|
5892
|
+
headers=headers,
|
5893
|
+
query=OpenApiUtilClient.query(query),
|
5894
|
+
body=OpenApiUtilClient.parse_to_map(request.body)
|
5895
|
+
)
|
5896
|
+
params = open_api_models.Params(
|
5897
|
+
action='PutScalingConfig',
|
5898
|
+
version='2023-03-30',
|
5899
|
+
protocol='HTTPS',
|
5900
|
+
pathname=f'/2023-03-30/functions/{OpenApiUtilClient.get_encode_param(function_name)}/scaling-config',
|
5901
|
+
method='PUT',
|
5902
|
+
auth_type='AK',
|
5903
|
+
style='ROA',
|
5904
|
+
req_body_type='json',
|
5905
|
+
body_type='json'
|
5906
|
+
)
|
5907
|
+
return TeaCore.from_map(
|
5908
|
+
fc20230330_models.PutScalingConfigResponse(),
|
5909
|
+
await self.call_api_async(params, req, runtime)
|
5910
|
+
)
|
5911
|
+
|
5912
|
+
def put_scaling_config(
|
5913
|
+
self,
|
5914
|
+
function_name: str,
|
5915
|
+
request: fc20230330_models.PutScalingConfigRequest,
|
5916
|
+
) -> fc20230330_models.PutScalingConfigResponse:
|
5917
|
+
"""
|
5918
|
+
@summary 设置弹性配置
|
5919
|
+
|
5920
|
+
@param request: PutScalingConfigRequest
|
5921
|
+
@return: PutScalingConfigResponse
|
5922
|
+
"""
|
5923
|
+
runtime = util_models.RuntimeOptions()
|
5924
|
+
headers = {}
|
5925
|
+
return self.put_scaling_config_with_options(function_name, request, headers, runtime)
|
5926
|
+
|
5927
|
+
async def put_scaling_config_async(
|
5928
|
+
self,
|
5929
|
+
function_name: str,
|
5930
|
+
request: fc20230330_models.PutScalingConfigRequest,
|
5931
|
+
) -> fc20230330_models.PutScalingConfigResponse:
|
5932
|
+
"""
|
5933
|
+
@summary 设置弹性配置
|
5934
|
+
|
5935
|
+
@param request: PutScalingConfigRequest
|
5936
|
+
@return: PutScalingConfigResponse
|
5937
|
+
"""
|
5938
|
+
runtime = util_models.RuntimeOptions()
|
5939
|
+
headers = {}
|
5940
|
+
return await self.put_scaling_config_with_options_async(function_name, request, headers, runtime)
|
5941
|
+
|
5406
5942
|
def stop_async_task_with_options(
|
5407
5943
|
self,
|
5408
5944
|
function_name: str,
|