alibabacloud-ehpcinstant20230701 1.1.0__py3-none-any.whl → 1.2.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.

Potentially problematic release.


This version of alibabacloud-ehpcinstant20230701 might be problematic. Click here for more details.

@@ -1 +1 @@
1
- __version__ = '1.1.0'
1
+ __version__ = '1.2.0'
@@ -293,6 +293,118 @@ class Client(OpenApiClient):
293
293
  runtime = util_models.RuntimeOptions()
294
294
  return await self.create_job_with_options_async(request, runtime)
295
295
 
296
+ def create_pool_with_options(
297
+ self,
298
+ tmp_req: ehpc_instant_20230701_models.CreatePoolRequest,
299
+ runtime: util_models.RuntimeOptions,
300
+ ) -> ehpc_instant_20230701_models.CreatePoolResponse:
301
+ """
302
+ @summary 创建资源池
303
+
304
+ @param tmp_req: CreatePoolRequest
305
+ @param runtime: runtime options for this request RuntimeOptions
306
+ @return: CreatePoolResponse
307
+ """
308
+ UtilClient.validate_model(tmp_req)
309
+ request = ehpc_instant_20230701_models.CreatePoolShrinkRequest()
310
+ OpenApiUtilClient.convert(tmp_req, request)
311
+ if not UtilClient.is_unset(tmp_req.resource_limits):
312
+ request.resource_limits_shrink = OpenApiUtilClient.array_to_string_with_specified_style(tmp_req.resource_limits, 'ResourceLimits', 'json')
313
+ query = {}
314
+ if not UtilClient.is_unset(request.pool_name):
315
+ query['PoolName'] = request.pool_name
316
+ if not UtilClient.is_unset(request.priority):
317
+ query['Priority'] = request.priority
318
+ if not UtilClient.is_unset(request.resource_limits_shrink):
319
+ query['ResourceLimits'] = request.resource_limits_shrink
320
+ req = open_api_models.OpenApiRequest(
321
+ query=OpenApiUtilClient.query(query)
322
+ )
323
+ params = open_api_models.Params(
324
+ action='CreatePool',
325
+ version='2023-07-01',
326
+ protocol='HTTPS',
327
+ pathname='/',
328
+ method='POST',
329
+ auth_type='AK',
330
+ style='RPC',
331
+ req_body_type='formData',
332
+ body_type='json'
333
+ )
334
+ return TeaCore.from_map(
335
+ ehpc_instant_20230701_models.CreatePoolResponse(),
336
+ self.call_api(params, req, runtime)
337
+ )
338
+
339
+ async def create_pool_with_options_async(
340
+ self,
341
+ tmp_req: ehpc_instant_20230701_models.CreatePoolRequest,
342
+ runtime: util_models.RuntimeOptions,
343
+ ) -> ehpc_instant_20230701_models.CreatePoolResponse:
344
+ """
345
+ @summary 创建资源池
346
+
347
+ @param tmp_req: CreatePoolRequest
348
+ @param runtime: runtime options for this request RuntimeOptions
349
+ @return: CreatePoolResponse
350
+ """
351
+ UtilClient.validate_model(tmp_req)
352
+ request = ehpc_instant_20230701_models.CreatePoolShrinkRequest()
353
+ OpenApiUtilClient.convert(tmp_req, request)
354
+ if not UtilClient.is_unset(tmp_req.resource_limits):
355
+ request.resource_limits_shrink = OpenApiUtilClient.array_to_string_with_specified_style(tmp_req.resource_limits, 'ResourceLimits', 'json')
356
+ query = {}
357
+ if not UtilClient.is_unset(request.pool_name):
358
+ query['PoolName'] = request.pool_name
359
+ if not UtilClient.is_unset(request.priority):
360
+ query['Priority'] = request.priority
361
+ if not UtilClient.is_unset(request.resource_limits_shrink):
362
+ query['ResourceLimits'] = request.resource_limits_shrink
363
+ req = open_api_models.OpenApiRequest(
364
+ query=OpenApiUtilClient.query(query)
365
+ )
366
+ params = open_api_models.Params(
367
+ action='CreatePool',
368
+ version='2023-07-01',
369
+ protocol='HTTPS',
370
+ pathname='/',
371
+ method='POST',
372
+ auth_type='AK',
373
+ style='RPC',
374
+ req_body_type='formData',
375
+ body_type='json'
376
+ )
377
+ return TeaCore.from_map(
378
+ ehpc_instant_20230701_models.CreatePoolResponse(),
379
+ await self.call_api_async(params, req, runtime)
380
+ )
381
+
382
+ def create_pool(
383
+ self,
384
+ request: ehpc_instant_20230701_models.CreatePoolRequest,
385
+ ) -> ehpc_instant_20230701_models.CreatePoolResponse:
386
+ """
387
+ @summary 创建资源池
388
+
389
+ @param request: CreatePoolRequest
390
+ @return: CreatePoolResponse
391
+ """
392
+ runtime = util_models.RuntimeOptions()
393
+ return self.create_pool_with_options(request, runtime)
394
+
395
+ async def create_pool_async(
396
+ self,
397
+ request: ehpc_instant_20230701_models.CreatePoolRequest,
398
+ ) -> ehpc_instant_20230701_models.CreatePoolResponse:
399
+ """
400
+ @summary 创建资源池
401
+
402
+ @param request: CreatePoolRequest
403
+ @return: CreatePoolResponse
404
+ """
405
+ runtime = util_models.RuntimeOptions()
406
+ return await self.create_pool_with_options_async(request, runtime)
407
+
296
408
  def delete_jobs_with_options(
297
409
  self,
298
410
  tmp_req: ehpc_instant_20230701_models.DeleteJobsRequest,
@@ -405,6 +517,102 @@ class Client(OpenApiClient):
405
517
  runtime = util_models.RuntimeOptions()
406
518
  return await self.delete_jobs_with_options_async(request, runtime)
407
519
 
520
+ def delete_pool_with_options(
521
+ self,
522
+ request: ehpc_instant_20230701_models.DeletePoolRequest,
523
+ runtime: util_models.RuntimeOptions,
524
+ ) -> ehpc_instant_20230701_models.DeletePoolResponse:
525
+ """
526
+ @summary 删除资源池
527
+
528
+ @param request: DeletePoolRequest
529
+ @param runtime: runtime options for this request RuntimeOptions
530
+ @return: DeletePoolResponse
531
+ """
532
+ UtilClient.validate_model(request)
533
+ query = {}
534
+ if not UtilClient.is_unset(request.pool_name):
535
+ query['PoolName'] = request.pool_name
536
+ req = open_api_models.OpenApiRequest(
537
+ query=OpenApiUtilClient.query(query)
538
+ )
539
+ params = open_api_models.Params(
540
+ action='DeletePool',
541
+ version='2023-07-01',
542
+ protocol='HTTPS',
543
+ pathname='/',
544
+ method='POST',
545
+ auth_type='AK',
546
+ style='RPC',
547
+ req_body_type='formData',
548
+ body_type='json'
549
+ )
550
+ return TeaCore.from_map(
551
+ ehpc_instant_20230701_models.DeletePoolResponse(),
552
+ self.call_api(params, req, runtime)
553
+ )
554
+
555
+ async def delete_pool_with_options_async(
556
+ self,
557
+ request: ehpc_instant_20230701_models.DeletePoolRequest,
558
+ runtime: util_models.RuntimeOptions,
559
+ ) -> ehpc_instant_20230701_models.DeletePoolResponse:
560
+ """
561
+ @summary 删除资源池
562
+
563
+ @param request: DeletePoolRequest
564
+ @param runtime: runtime options for this request RuntimeOptions
565
+ @return: DeletePoolResponse
566
+ """
567
+ UtilClient.validate_model(request)
568
+ query = {}
569
+ if not UtilClient.is_unset(request.pool_name):
570
+ query['PoolName'] = request.pool_name
571
+ req = open_api_models.OpenApiRequest(
572
+ query=OpenApiUtilClient.query(query)
573
+ )
574
+ params = open_api_models.Params(
575
+ action='DeletePool',
576
+ version='2023-07-01',
577
+ protocol='HTTPS',
578
+ pathname='/',
579
+ method='POST',
580
+ auth_type='AK',
581
+ style='RPC',
582
+ req_body_type='formData',
583
+ body_type='json'
584
+ )
585
+ return TeaCore.from_map(
586
+ ehpc_instant_20230701_models.DeletePoolResponse(),
587
+ await self.call_api_async(params, req, runtime)
588
+ )
589
+
590
+ def delete_pool(
591
+ self,
592
+ request: ehpc_instant_20230701_models.DeletePoolRequest,
593
+ ) -> ehpc_instant_20230701_models.DeletePoolResponse:
594
+ """
595
+ @summary 删除资源池
596
+
597
+ @param request: DeletePoolRequest
598
+ @return: DeletePoolResponse
599
+ """
600
+ runtime = util_models.RuntimeOptions()
601
+ return self.delete_pool_with_options(request, runtime)
602
+
603
+ async def delete_pool_async(
604
+ self,
605
+ request: ehpc_instant_20230701_models.DeletePoolRequest,
606
+ ) -> ehpc_instant_20230701_models.DeletePoolResponse:
607
+ """
608
+ @summary 删除资源池
609
+
610
+ @param request: DeletePoolRequest
611
+ @return: DeletePoolResponse
612
+ """
613
+ runtime = util_models.RuntimeOptions()
614
+ return await self.delete_pool_with_options_async(request, runtime)
615
+
408
616
  def describe_job_metric_data_with_options(
409
617
  self,
410
618
  tmp_req: ehpc_instant_20230701_models.DescribeJobMetricDataRequest,
@@ -633,6 +841,118 @@ class Client(OpenApiClient):
633
841
  runtime = util_models.RuntimeOptions()
634
842
  return await self.describe_job_metric_last_with_options_async(request, runtime)
635
843
 
844
+ def get_app_versions_with_options(
845
+ self,
846
+ request: ehpc_instant_20230701_models.GetAppVersionsRequest,
847
+ runtime: util_models.RuntimeOptions,
848
+ ) -> ehpc_instant_20230701_models.GetAppVersionsResponse:
849
+ """
850
+ @summary 查看应用版本列表
851
+
852
+ @param request: GetAppVersionsRequest
853
+ @param runtime: runtime options for this request RuntimeOptions
854
+ @return: GetAppVersionsResponse
855
+ """
856
+ UtilClient.validate_model(request)
857
+ query = {}
858
+ if not UtilClient.is_unset(request.app_name):
859
+ query['AppName'] = request.app_name
860
+ if not UtilClient.is_unset(request.image_category):
861
+ query['ImageCategory'] = request.image_category
862
+ if not UtilClient.is_unset(request.image_type):
863
+ query['ImageType'] = request.image_type
864
+ if not UtilClient.is_unset(request.page_number):
865
+ query['PageNumber'] = request.page_number
866
+ if not UtilClient.is_unset(request.page_size):
867
+ query['PageSize'] = request.page_size
868
+ req = open_api_models.OpenApiRequest(
869
+ query=OpenApiUtilClient.query(query)
870
+ )
871
+ params = open_api_models.Params(
872
+ action='GetAppVersions',
873
+ version='2023-07-01',
874
+ protocol='HTTPS',
875
+ pathname='/',
876
+ method='POST',
877
+ auth_type='AK',
878
+ style='RPC',
879
+ req_body_type='formData',
880
+ body_type='json'
881
+ )
882
+ return TeaCore.from_map(
883
+ ehpc_instant_20230701_models.GetAppVersionsResponse(),
884
+ self.call_api(params, req, runtime)
885
+ )
886
+
887
+ async def get_app_versions_with_options_async(
888
+ self,
889
+ request: ehpc_instant_20230701_models.GetAppVersionsRequest,
890
+ runtime: util_models.RuntimeOptions,
891
+ ) -> ehpc_instant_20230701_models.GetAppVersionsResponse:
892
+ """
893
+ @summary 查看应用版本列表
894
+
895
+ @param request: GetAppVersionsRequest
896
+ @param runtime: runtime options for this request RuntimeOptions
897
+ @return: GetAppVersionsResponse
898
+ """
899
+ UtilClient.validate_model(request)
900
+ query = {}
901
+ if not UtilClient.is_unset(request.app_name):
902
+ query['AppName'] = request.app_name
903
+ if not UtilClient.is_unset(request.image_category):
904
+ query['ImageCategory'] = request.image_category
905
+ if not UtilClient.is_unset(request.image_type):
906
+ query['ImageType'] = request.image_type
907
+ if not UtilClient.is_unset(request.page_number):
908
+ query['PageNumber'] = request.page_number
909
+ if not UtilClient.is_unset(request.page_size):
910
+ query['PageSize'] = request.page_size
911
+ req = open_api_models.OpenApiRequest(
912
+ query=OpenApiUtilClient.query(query)
913
+ )
914
+ params = open_api_models.Params(
915
+ action='GetAppVersions',
916
+ version='2023-07-01',
917
+ protocol='HTTPS',
918
+ pathname='/',
919
+ method='POST',
920
+ auth_type='AK',
921
+ style='RPC',
922
+ req_body_type='formData',
923
+ body_type='json'
924
+ )
925
+ return TeaCore.from_map(
926
+ ehpc_instant_20230701_models.GetAppVersionsResponse(),
927
+ await self.call_api_async(params, req, runtime)
928
+ )
929
+
930
+ def get_app_versions(
931
+ self,
932
+ request: ehpc_instant_20230701_models.GetAppVersionsRequest,
933
+ ) -> ehpc_instant_20230701_models.GetAppVersionsResponse:
934
+ """
935
+ @summary 查看应用版本列表
936
+
937
+ @param request: GetAppVersionsRequest
938
+ @return: GetAppVersionsResponse
939
+ """
940
+ runtime = util_models.RuntimeOptions()
941
+ return self.get_app_versions_with_options(request, runtime)
942
+
943
+ async def get_app_versions_async(
944
+ self,
945
+ request: ehpc_instant_20230701_models.GetAppVersionsRequest,
946
+ ) -> ehpc_instant_20230701_models.GetAppVersionsResponse:
947
+ """
948
+ @summary 查看应用版本列表
949
+
950
+ @param request: GetAppVersionsRequest
951
+ @return: GetAppVersionsResponse
952
+ """
953
+ runtime = util_models.RuntimeOptions()
954
+ return await self.get_app_versions_with_options_async(request, runtime)
955
+
636
956
  def get_image_with_options(
637
957
  self,
638
958
  request: ehpc_instant_20230701_models.GetImageRequest,
@@ -833,6 +1153,102 @@ class Client(OpenApiClient):
833
1153
  runtime = util_models.RuntimeOptions()
834
1154
  return await self.get_job_with_options_async(request, runtime)
835
1155
 
1156
+ def get_pool_with_options(
1157
+ self,
1158
+ request: ehpc_instant_20230701_models.GetPoolRequest,
1159
+ runtime: util_models.RuntimeOptions,
1160
+ ) -> ehpc_instant_20230701_models.GetPoolResponse:
1161
+ """
1162
+ @summary 查询队列详细信息
1163
+
1164
+ @param request: GetPoolRequest
1165
+ @param runtime: runtime options for this request RuntimeOptions
1166
+ @return: GetPoolResponse
1167
+ """
1168
+ UtilClient.validate_model(request)
1169
+ query = {}
1170
+ if not UtilClient.is_unset(request.pool_name):
1171
+ query['PoolName'] = request.pool_name
1172
+ req = open_api_models.OpenApiRequest(
1173
+ query=OpenApiUtilClient.query(query)
1174
+ )
1175
+ params = open_api_models.Params(
1176
+ action='GetPool',
1177
+ version='2023-07-01',
1178
+ protocol='HTTPS',
1179
+ pathname='/',
1180
+ method='POST',
1181
+ auth_type='AK',
1182
+ style='RPC',
1183
+ req_body_type='formData',
1184
+ body_type='json'
1185
+ )
1186
+ return TeaCore.from_map(
1187
+ ehpc_instant_20230701_models.GetPoolResponse(),
1188
+ self.call_api(params, req, runtime)
1189
+ )
1190
+
1191
+ async def get_pool_with_options_async(
1192
+ self,
1193
+ request: ehpc_instant_20230701_models.GetPoolRequest,
1194
+ runtime: util_models.RuntimeOptions,
1195
+ ) -> ehpc_instant_20230701_models.GetPoolResponse:
1196
+ """
1197
+ @summary 查询队列详细信息
1198
+
1199
+ @param request: GetPoolRequest
1200
+ @param runtime: runtime options for this request RuntimeOptions
1201
+ @return: GetPoolResponse
1202
+ """
1203
+ UtilClient.validate_model(request)
1204
+ query = {}
1205
+ if not UtilClient.is_unset(request.pool_name):
1206
+ query['PoolName'] = request.pool_name
1207
+ req = open_api_models.OpenApiRequest(
1208
+ query=OpenApiUtilClient.query(query)
1209
+ )
1210
+ params = open_api_models.Params(
1211
+ action='GetPool',
1212
+ version='2023-07-01',
1213
+ protocol='HTTPS',
1214
+ pathname='/',
1215
+ method='POST',
1216
+ auth_type='AK',
1217
+ style='RPC',
1218
+ req_body_type='formData',
1219
+ body_type='json'
1220
+ )
1221
+ return TeaCore.from_map(
1222
+ ehpc_instant_20230701_models.GetPoolResponse(),
1223
+ await self.call_api_async(params, req, runtime)
1224
+ )
1225
+
1226
+ def get_pool(
1227
+ self,
1228
+ request: ehpc_instant_20230701_models.GetPoolRequest,
1229
+ ) -> ehpc_instant_20230701_models.GetPoolResponse:
1230
+ """
1231
+ @summary 查询队列详细信息
1232
+
1233
+ @param request: GetPoolRequest
1234
+ @return: GetPoolResponse
1235
+ """
1236
+ runtime = util_models.RuntimeOptions()
1237
+ return self.get_pool_with_options(request, runtime)
1238
+
1239
+ async def get_pool_async(
1240
+ self,
1241
+ request: ehpc_instant_20230701_models.GetPoolRequest,
1242
+ ) -> ehpc_instant_20230701_models.GetPoolResponse:
1243
+ """
1244
+ @summary 查询队列详细信息
1245
+
1246
+ @param request: GetPoolRequest
1247
+ @return: GetPoolResponse
1248
+ """
1249
+ runtime = util_models.RuntimeOptions()
1250
+ return await self.get_pool_with_options_async(request, runtime)
1251
+
836
1252
  def list_executors_with_options(
837
1253
  self,
838
1254
  tmp_req: ehpc_instant_20230701_models.ListExecutorsRequest,
@@ -973,6 +1389,8 @@ class Client(OpenApiClient):
973
1389
  query['ImageNames'] = request.image_names_shrink
974
1390
  if not UtilClient.is_unset(request.image_type):
975
1391
  query['ImageType'] = request.image_type
1392
+ if not UtilClient.is_unset(request.mode):
1393
+ query['Mode'] = request.mode
976
1394
  if not UtilClient.is_unset(request.page_number):
977
1395
  query['PageNumber'] = request.page_number
978
1396
  if not UtilClient.is_unset(request.page_size):
@@ -1024,6 +1442,8 @@ class Client(OpenApiClient):
1024
1442
  query['ImageNames'] = request.image_names_shrink
1025
1443
  if not UtilClient.is_unset(request.image_type):
1026
1444
  query['ImageType'] = request.image_type
1445
+ if not UtilClient.is_unset(request.mode):
1446
+ query['Mode'] = request.mode
1027
1447
  if not UtilClient.is_unset(request.page_number):
1028
1448
  query['PageNumber'] = request.page_number
1029
1449
  if not UtilClient.is_unset(request.page_size):
@@ -1301,6 +1721,118 @@ class Client(OpenApiClient):
1301
1721
  runtime = util_models.RuntimeOptions()
1302
1722
  return await self.list_jobs_with_options_async(request, runtime)
1303
1723
 
1724
+ def list_pools_with_options(
1725
+ self,
1726
+ tmp_req: ehpc_instant_20230701_models.ListPoolsRequest,
1727
+ runtime: util_models.RuntimeOptions,
1728
+ ) -> ehpc_instant_20230701_models.ListPoolsResponse:
1729
+ """
1730
+ @summary 查询资源池列表
1731
+
1732
+ @param tmp_req: ListPoolsRequest
1733
+ @param runtime: runtime options for this request RuntimeOptions
1734
+ @return: ListPoolsResponse
1735
+ """
1736
+ UtilClient.validate_model(tmp_req)
1737
+ request = ehpc_instant_20230701_models.ListPoolsShrinkRequest()
1738
+ OpenApiUtilClient.convert(tmp_req, request)
1739
+ if not UtilClient.is_unset(tmp_req.filter):
1740
+ request.filter_shrink = OpenApiUtilClient.array_to_string_with_specified_style(tmp_req.filter, 'Filter', 'json')
1741
+ query = {}
1742
+ if not UtilClient.is_unset(request.filter_shrink):
1743
+ query['Filter'] = request.filter_shrink
1744
+ if not UtilClient.is_unset(request.page_number):
1745
+ query['PageNumber'] = request.page_number
1746
+ if not UtilClient.is_unset(request.page_size):
1747
+ query['PageSize'] = request.page_size
1748
+ req = open_api_models.OpenApiRequest(
1749
+ query=OpenApiUtilClient.query(query)
1750
+ )
1751
+ params = open_api_models.Params(
1752
+ action='ListPools',
1753
+ version='2023-07-01',
1754
+ protocol='HTTPS',
1755
+ pathname='/',
1756
+ method='POST',
1757
+ auth_type='AK',
1758
+ style='RPC',
1759
+ req_body_type='formData',
1760
+ body_type='json'
1761
+ )
1762
+ return TeaCore.from_map(
1763
+ ehpc_instant_20230701_models.ListPoolsResponse(),
1764
+ self.call_api(params, req, runtime)
1765
+ )
1766
+
1767
+ async def list_pools_with_options_async(
1768
+ self,
1769
+ tmp_req: ehpc_instant_20230701_models.ListPoolsRequest,
1770
+ runtime: util_models.RuntimeOptions,
1771
+ ) -> ehpc_instant_20230701_models.ListPoolsResponse:
1772
+ """
1773
+ @summary 查询资源池列表
1774
+
1775
+ @param tmp_req: ListPoolsRequest
1776
+ @param runtime: runtime options for this request RuntimeOptions
1777
+ @return: ListPoolsResponse
1778
+ """
1779
+ UtilClient.validate_model(tmp_req)
1780
+ request = ehpc_instant_20230701_models.ListPoolsShrinkRequest()
1781
+ OpenApiUtilClient.convert(tmp_req, request)
1782
+ if not UtilClient.is_unset(tmp_req.filter):
1783
+ request.filter_shrink = OpenApiUtilClient.array_to_string_with_specified_style(tmp_req.filter, 'Filter', 'json')
1784
+ query = {}
1785
+ if not UtilClient.is_unset(request.filter_shrink):
1786
+ query['Filter'] = request.filter_shrink
1787
+ if not UtilClient.is_unset(request.page_number):
1788
+ query['PageNumber'] = request.page_number
1789
+ if not UtilClient.is_unset(request.page_size):
1790
+ query['PageSize'] = request.page_size
1791
+ req = open_api_models.OpenApiRequest(
1792
+ query=OpenApiUtilClient.query(query)
1793
+ )
1794
+ params = open_api_models.Params(
1795
+ action='ListPools',
1796
+ version='2023-07-01',
1797
+ protocol='HTTPS',
1798
+ pathname='/',
1799
+ method='POST',
1800
+ auth_type='AK',
1801
+ style='RPC',
1802
+ req_body_type='formData',
1803
+ body_type='json'
1804
+ )
1805
+ return TeaCore.from_map(
1806
+ ehpc_instant_20230701_models.ListPoolsResponse(),
1807
+ await self.call_api_async(params, req, runtime)
1808
+ )
1809
+
1810
+ def list_pools(
1811
+ self,
1812
+ request: ehpc_instant_20230701_models.ListPoolsRequest,
1813
+ ) -> ehpc_instant_20230701_models.ListPoolsResponse:
1814
+ """
1815
+ @summary 查询资源池列表
1816
+
1817
+ @param request: ListPoolsRequest
1818
+ @return: ListPoolsResponse
1819
+ """
1820
+ runtime = util_models.RuntimeOptions()
1821
+ return self.list_pools_with_options(request, runtime)
1822
+
1823
+ async def list_pools_async(
1824
+ self,
1825
+ request: ehpc_instant_20230701_models.ListPoolsRequest,
1826
+ ) -> ehpc_instant_20230701_models.ListPoolsResponse:
1827
+ """
1828
+ @summary 查询资源池列表
1829
+
1830
+ @param request: ListPoolsRequest
1831
+ @return: ListPoolsResponse
1832
+ """
1833
+ runtime = util_models.RuntimeOptions()
1834
+ return await self.list_pools_with_options_async(request, runtime)
1835
+
1304
1836
  def list_tag_resources_with_options(
1305
1837
  self,
1306
1838
  request: ehpc_instant_20230701_models.ListTagResourcesRequest,
@@ -1724,3 +2256,115 @@ class Client(OpenApiClient):
1724
2256
  """
1725
2257
  runtime = util_models.RuntimeOptions()
1726
2258
  return await self.un_tag_resources_with_options_async(request, runtime)
2259
+
2260
+ def update_pool_with_options(
2261
+ self,
2262
+ tmp_req: ehpc_instant_20230701_models.UpdatePoolRequest,
2263
+ runtime: util_models.RuntimeOptions,
2264
+ ) -> ehpc_instant_20230701_models.UpdatePoolResponse:
2265
+ """
2266
+ @summary 更新资源池
2267
+
2268
+ @param tmp_req: UpdatePoolRequest
2269
+ @param runtime: runtime options for this request RuntimeOptions
2270
+ @return: UpdatePoolResponse
2271
+ """
2272
+ UtilClient.validate_model(tmp_req)
2273
+ request = ehpc_instant_20230701_models.UpdatePoolShrinkRequest()
2274
+ OpenApiUtilClient.convert(tmp_req, request)
2275
+ if not UtilClient.is_unset(tmp_req.resource_limits):
2276
+ request.resource_limits_shrink = OpenApiUtilClient.array_to_string_with_specified_style(tmp_req.resource_limits, 'ResourceLimits', 'json')
2277
+ query = {}
2278
+ if not UtilClient.is_unset(request.pool_name):
2279
+ query['PoolName'] = request.pool_name
2280
+ if not UtilClient.is_unset(request.priority):
2281
+ query['Priority'] = request.priority
2282
+ if not UtilClient.is_unset(request.resource_limits_shrink):
2283
+ query['ResourceLimits'] = request.resource_limits_shrink
2284
+ req = open_api_models.OpenApiRequest(
2285
+ query=OpenApiUtilClient.query(query)
2286
+ )
2287
+ params = open_api_models.Params(
2288
+ action='UpdatePool',
2289
+ version='2023-07-01',
2290
+ protocol='HTTPS',
2291
+ pathname='/',
2292
+ method='POST',
2293
+ auth_type='AK',
2294
+ style='RPC',
2295
+ req_body_type='formData',
2296
+ body_type='json'
2297
+ )
2298
+ return TeaCore.from_map(
2299
+ ehpc_instant_20230701_models.UpdatePoolResponse(),
2300
+ self.call_api(params, req, runtime)
2301
+ )
2302
+
2303
+ async def update_pool_with_options_async(
2304
+ self,
2305
+ tmp_req: ehpc_instant_20230701_models.UpdatePoolRequest,
2306
+ runtime: util_models.RuntimeOptions,
2307
+ ) -> ehpc_instant_20230701_models.UpdatePoolResponse:
2308
+ """
2309
+ @summary 更新资源池
2310
+
2311
+ @param tmp_req: UpdatePoolRequest
2312
+ @param runtime: runtime options for this request RuntimeOptions
2313
+ @return: UpdatePoolResponse
2314
+ """
2315
+ UtilClient.validate_model(tmp_req)
2316
+ request = ehpc_instant_20230701_models.UpdatePoolShrinkRequest()
2317
+ OpenApiUtilClient.convert(tmp_req, request)
2318
+ if not UtilClient.is_unset(tmp_req.resource_limits):
2319
+ request.resource_limits_shrink = OpenApiUtilClient.array_to_string_with_specified_style(tmp_req.resource_limits, 'ResourceLimits', 'json')
2320
+ query = {}
2321
+ if not UtilClient.is_unset(request.pool_name):
2322
+ query['PoolName'] = request.pool_name
2323
+ if not UtilClient.is_unset(request.priority):
2324
+ query['Priority'] = request.priority
2325
+ if not UtilClient.is_unset(request.resource_limits_shrink):
2326
+ query['ResourceLimits'] = request.resource_limits_shrink
2327
+ req = open_api_models.OpenApiRequest(
2328
+ query=OpenApiUtilClient.query(query)
2329
+ )
2330
+ params = open_api_models.Params(
2331
+ action='UpdatePool',
2332
+ version='2023-07-01',
2333
+ protocol='HTTPS',
2334
+ pathname='/',
2335
+ method='POST',
2336
+ auth_type='AK',
2337
+ style='RPC',
2338
+ req_body_type='formData',
2339
+ body_type='json'
2340
+ )
2341
+ return TeaCore.from_map(
2342
+ ehpc_instant_20230701_models.UpdatePoolResponse(),
2343
+ await self.call_api_async(params, req, runtime)
2344
+ )
2345
+
2346
+ def update_pool(
2347
+ self,
2348
+ request: ehpc_instant_20230701_models.UpdatePoolRequest,
2349
+ ) -> ehpc_instant_20230701_models.UpdatePoolResponse:
2350
+ """
2351
+ @summary 更新资源池
2352
+
2353
+ @param request: UpdatePoolRequest
2354
+ @return: UpdatePoolResponse
2355
+ """
2356
+ runtime = util_models.RuntimeOptions()
2357
+ return self.update_pool_with_options(request, runtime)
2358
+
2359
+ async def update_pool_async(
2360
+ self,
2361
+ request: ehpc_instant_20230701_models.UpdatePoolRequest,
2362
+ ) -> ehpc_instant_20230701_models.UpdatePoolResponse:
2363
+ """
2364
+ @summary 更新资源池
2365
+
2366
+ @param request: UpdatePoolRequest
2367
+ @return: UpdatePoolResponse
2368
+ """
2369
+ runtime = util_models.RuntimeOptions()
2370
+ return await self.update_pool_with_options_async(request, runtime)