tccli-intl-en 3.1.11.1__py2.py3-none-any.whl → 3.1.39.1__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.
- tccli/__init__.py +1 -1
- tccli/services/__init__.py +9 -0
- tccli/services/advisor/advisor_client.py +56 -0
- tccli/services/advisor/v20200721/api.json +34 -0
- tccli/services/advisor/v20200721/examples.json +8 -0
- tccli/services/ai3d/__init__.py +4 -0
- tccli/services/ai3d/ai3d_client.py +266 -0
- tccli/services/ai3d/v20250513/api.json +264 -0
- tccli/services/ai3d/v20250513/examples.json +20 -0
- tccli/services/autoscaling/v20180419/api.json +41 -13
- tccli/services/billing/billing_client.py +172 -4
- tccli/services/billing/v20180709/api.json +332 -1
- tccli/services/billing/v20180709/examples.json +24 -0
- tccli/services/ccc/v20200210/api.json +71 -26
- tccli/services/cdb/cdb_client.py +1128 -288
- tccli/services/cdb/v20170320/api.json +2166 -335
- tccli/services/cdb/v20170320/examples.json +126 -6
- tccli/services/cdn/v20180606/api.json +22 -22
- tccli/services/cdn/v20180606/examples.json +1 -1
- tccli/services/ckafka/ckafka_client.py +120 -8
- tccli/services/ckafka/v20190819/api.json +525 -180
- tccli/services/ckafka/v20190819/examples.json +30 -20
- tccli/services/clb/v20180317/api.json +87 -87
- tccli/services/csip/csip_client.py +392 -0
- tccli/services/csip/v20221121/api.json +2050 -284
- tccli/services/csip/v20221121/examples.json +56 -0
- tccli/services/cvm/v20170312/api.json +23 -23
- tccli/services/cvm/v20170312/examples.json +32 -32
- tccli/services/emr/v20190103/api.json +6 -6
- tccli/services/faceid/v20180301/api.json +102 -52
- tccli/services/faceid/v20180301/examples.json +3 -9
- tccli/services/hunyuan/__init__.py +4 -0
- tccli/services/hunyuan/hunyuan_client.py +714 -0
- tccli/services/hunyuan/v20230901/api.json +1131 -0
- tccli/services/hunyuan/v20230901/examples.json +84 -0
- tccli/services/lighthouse/lighthouse_client.py +360 -24
- tccli/services/lighthouse/v20200324/api.json +488 -0
- tccli/services/lighthouse/v20200324/examples.json +54 -0
- tccli/services/lkeap/v20240522/api.json +36 -0
- tccli/services/lkeap/v20240522/examples.json +1 -1
- tccli/services/mdl/mdl_client.py +192 -24
- tccli/services/mdl/v20200326/api.json +761 -77
- tccli/services/mdl/v20200326/examples.json +24 -0
- tccli/services/mdp/v20200527/api.json +191 -28
- tccli/services/mongodb/v20190725/api.json +39 -39
- tccli/services/monitor/v20180724/api.json +5 -5
- tccli/services/mps/mps_client.py +397 -61
- tccli/services/mps/v20190612/api.json +1190 -132
- tccli/services/mps/v20190612/examples.json +76 -22
- tccli/services/mqtt/__init__.py +4 -0
- tccli/services/mqtt/mqtt_client.py +1610 -0
- tccli/services/mqtt/v20240516/api.json +3057 -0
- tccli/services/mqtt/v20240516/examples.json +213 -0
- tccli/services/ocr/v20181119/api.json +23 -3
- tccli/services/ocr/v20181119/examples.json +6 -6
- tccli/services/redis/v20180412/api.json +12 -12
- tccli/services/ses/ses_client.py +348 -12
- tccli/services/ses/v20201002/api.json +1197 -256
- tccli/services/ses/v20201002/examples.json +78 -24
- tccli/services/tcsas/tcsas_client.py +2281 -209
- tccli/services/tcsas/v20250106/api.json +8410 -3423
- tccli/services/tcsas/v20250106/examples.json +308 -12
- tccli/services/tdmq/v20200217/api.json +4 -4
- tccli/services/teo/teo_client.py +56 -0
- tccli/services/teo/v20220901/api.json +111 -12
- tccli/services/teo/v20220901/examples.json +8 -0
- tccli/services/tke/tke_client.py +168 -0
- tccli/services/tke/v20180525/api.json +227 -0
- tccli/services/tke/v20180525/examples.json +24 -0
- tccli/services/trocket/v20230308/api.json +96 -96
- tccli/services/trtc/v20190722/api.json +212 -144
- tccli/services/trtc/v20190722/examples.json +7 -7
- tccli/services/vod/v20180717/api.json +2929 -296
- tccli/services/vod/v20180717/examples.json +40 -6
- tccli/services/vod/vod_client.py +280 -0
- tccli/services/vpc/v20170312/api.json +80 -13
- tccli/services/vpc/v20170312/examples.json +17 -9
- tccli/services/vpc/vpc_client.py +64 -8
- {tccli_intl_en-3.1.11.1.dist-info → tccli_intl_en-3.1.39.1.dist-info}/METADATA +2 -2
- {tccli_intl_en-3.1.11.1.dist-info → tccli_intl_en-3.1.39.1.dist-info}/RECORD +84 -72
- {tccli_intl_en-3.1.11.1.dist-info → tccli_intl_en-3.1.39.1.dist-info}/WHEEL +1 -1
- {tccli_intl_en-3.1.11.1.dist-info → tccli_intl_en-3.1.39.1.dist-info}/LICENSE +0 -0
- {tccli_intl_en-3.1.11.1.dist-info → tccli_intl_en-3.1.39.1.dist-info}/entry_points.txt +0 -0
- {tccli_intl_en-3.1.11.1.dist-info → tccli_intl_en-3.1.39.1.dist-info}/top_level.txt +0 -0
|
@@ -3093,7 +3093,7 @@
|
|
|
3093
3093
|
},
|
|
3094
3094
|
{
|
|
3095
3095
|
"disabled": false,
|
|
3096
|
-
"document": "Cluster specification code.\nRefers to professional cluster specifications (https://www.tencentcloud.
|
|
3096
|
+
"document": "Cluster specification code.\nRefers to professional cluster specifications (https://www.tencentcloud.com/document/product/1179/83705?from_cn_redirect=1).",
|
|
3097
3097
|
"example": "PULSAR.P1.MINI2",
|
|
3098
3098
|
"member": "string",
|
|
3099
3099
|
"name": "ProductName",
|
|
@@ -3102,7 +3102,7 @@
|
|
|
3102
3102
|
},
|
|
3103
3103
|
{
|
|
3104
3104
|
"disabled": false,
|
|
3105
|
-
"document": "Specifies the storage specification.\nRefers to professional cluster specifications (https://www.tencentcloud.
|
|
3105
|
+
"document": "Specifies the storage specification.\nRefers to professional cluster specifications (https://www.tencentcloud.com/document/product/1179/83705?from_cn_redirect=1).",
|
|
3106
3106
|
"example": "200",
|
|
3107
3107
|
"member": "int64",
|
|
3108
3108
|
"name": "StorageSize",
|
|
@@ -3425,7 +3425,7 @@
|
|
|
3425
3425
|
},
|
|
3426
3426
|
{
|
|
3427
3427
|
"disabled": false,
|
|
3428
|
-
"document": "vpc ID, such as vpc-xxx. valid VpcId can be obtained by logging in to the virtual private cloud console (https://console.cloud.tencent.com/vpc/vpc?rid=1) or via api call to DescribeVpcEx (https://www.tencentcloud.
|
|
3428
|
+
"document": "vpc ID, such as vpc-xxx. valid VpcId can be obtained by logging in to the virtual private cloud console (https://console.cloud.tencent.com/vpc/vpc?rid=1) or via api call to DescribeVpcEx (https://www.tencentcloud.com/document/api/215/1372?from_cn_redirect=1), retrieving the unVpcId field from the api response. if both VpcId and SubnetId are set to DEFAULT when creating an instance, the DEFAULT vpc network will be forcibly used.",
|
|
3429
3429
|
"example": "vpc-5ghsr4p9",
|
|
3430
3430
|
"member": "string",
|
|
3431
3431
|
"name": "VpcId",
|
|
@@ -3434,7 +3434,7 @@
|
|
|
3434
3434
|
},
|
|
3435
3435
|
{
|
|
3436
3436
|
"disabled": false,
|
|
3437
|
-
"document": "The subnet ID of the vpc, such as subnet-xxx. valid subnet ids can be queried by logging in to the subnet console (https://console.cloud.tencent.com/vpc/subnet?rid=1) or by calling the api [DescribeSubnets](https://www.tencentcloud.
|
|
3437
|
+
"document": "The subnet ID of the vpc, such as subnet-xxx. valid subnet ids can be queried by logging in to the subnet console (https://console.cloud.tencent.com/vpc/subnet?rid=1) or by calling the api [DescribeSubnets](https://www.tencentcloud.com/document/api/215/15784?from_cn_redirect=1) and obtaining the unSubnetId field from the api response. if both SubnetId and VpcId are set to DEFAULT when creating an instance, the DEFAULT vpc network will be forcibly used.",
|
|
3438
3438
|
"example": "subnet-67y9wil4",
|
|
3439
3439
|
"member": "string",
|
|
3440
3440
|
"name": "SubnetId",
|
tccli/services/teo/teo_client.py
CHANGED
|
@@ -11899,6 +11899,61 @@ def doDeleteZone(args, parsed_globals):
|
|
|
11899
11899
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
11900
11900
|
|
|
11901
11901
|
|
|
11902
|
+
def doDescribeTimingL7OriginPullData(args, parsed_globals):
|
|
11903
|
+
g_param = parse_global_arg(parsed_globals)
|
|
11904
|
+
|
|
11905
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
|
11906
|
+
cred = credential.CVMRoleCredential()
|
|
11907
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
|
11908
|
+
cred = credential.STSAssumeRoleCredential(
|
|
11909
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
|
11910
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
|
11911
|
+
)
|
|
11912
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) \
|
|
11913
|
+
and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) \
|
|
11914
|
+
and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) \
|
|
11915
|
+
and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
|
11916
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
|
11917
|
+
else:
|
|
11918
|
+
cred = credential.Credential(
|
|
11919
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
|
11920
|
+
)
|
|
11921
|
+
http_profile = HttpProfile(
|
|
11922
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
|
11923
|
+
reqMethod="POST",
|
|
11924
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
|
11925
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
|
11926
|
+
)
|
|
11927
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="TC3-HMAC-SHA256")
|
|
11928
|
+
if g_param[OptionsDefine.Language]:
|
|
11929
|
+
profile.language = g_param[OptionsDefine.Language]
|
|
11930
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
|
11931
|
+
client = mod.TeoClient(cred, g_param[OptionsDefine.Region], profile)
|
|
11932
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
|
11933
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
|
11934
|
+
model = models.DescribeTimingL7OriginPullDataRequest()
|
|
11935
|
+
model.from_json_string(json.dumps(args))
|
|
11936
|
+
start_time = time.time()
|
|
11937
|
+
while True:
|
|
11938
|
+
rsp = client.DescribeTimingL7OriginPullData(model)
|
|
11939
|
+
result = rsp.to_json_string()
|
|
11940
|
+
try:
|
|
11941
|
+
json_obj = json.loads(result)
|
|
11942
|
+
except TypeError as e:
|
|
11943
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
|
11944
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
|
11945
|
+
break
|
|
11946
|
+
cur_time = time.time()
|
|
11947
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
|
11948
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
|
11949
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
|
11950
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
|
11951
|
+
else:
|
|
11952
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
|
11953
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
|
11954
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
11955
|
+
|
|
11956
|
+
|
|
11902
11957
|
def doApplyFreeCertificate(args, parsed_globals):
|
|
11903
11958
|
g_param = parse_global_arg(parsed_globals)
|
|
11904
11959
|
|
|
@@ -13613,6 +13668,7 @@ ACTION_MAP = {
|
|
|
13613
13668
|
"DescribeFunctions": doDescribeFunctions,
|
|
13614
13669
|
"ReclaimZone": doReclaimZone,
|
|
13615
13670
|
"DeleteZone": doDeleteZone,
|
|
13671
|
+
"DescribeTimingL7OriginPullData": doDescribeTimingL7OriginPullData,
|
|
13616
13672
|
"ApplyFreeCertificate": doApplyFreeCertificate,
|
|
13617
13673
|
"DescribeDDosAttackEvent": doDescribeDDosAttackEvent,
|
|
13618
13674
|
"DescribeEnvironments": doDescribeEnvironments,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"actions": {
|
|
3
3
|
"ApplyFreeCertificate": {
|
|
4
|
-
"document": "This API is used to apply for a free certificate. If you need to proceed with DNS delegated verification or file verification, you can call this API to initiate the certificate application and obtain the corresponding verification content based on the application method. The order for API calls is as follows:.\nStep 1: Call ApplyFreeCertificate, specify the verification method for free certificate application, and obtain the verification content.\nStep 2: Configure the corresponding domain as verification content.\nStep 3: Call CheckFreeCertificateVerification to verify. After verification passes, the free certificate application is completed.\nStep 4: Call ModifyHostsCertificate to issue a domain certificate configured to use the EdgeOne free certificate.\n\nThe application method introduction in the document: [Free Certificate Application Description](https://www.tencentcloud.
|
|
4
|
+
"document": "This API is used to apply for a free certificate. If you need to proceed with DNS delegated verification or file verification, you can call this API to initiate the certificate application and obtain the corresponding verification content based on the application method. The order for API calls is as follows:.\nStep 1: Call ApplyFreeCertificate, specify the verification method for free certificate application, and obtain the verification content.\nStep 2: Configure the corresponding domain as verification content.\nStep 3: Call CheckFreeCertificateVerification to verify. After verification passes, the free certificate application is completed.\nStep 4: Call ModifyHostsCertificate to issue a domain certificate configured to use the EdgeOne free certificate.\n\nThe application method introduction in the document: [Free Certificate Application Description](https://www.tencentcloud.com/document/product/1552/90437?from_cn_redirect=1). \ndescription:.\n- Only CNAME access mode can call this API to specify the free certificate application method. NS/DNSPod hosting access modes use automatic validation to apply for free certificates with no need to call this API.\n- If you need to switch the free certificate authentication method, you can call this API again by changing the VerificationMethod field to update it.\n- A domain name can only apply for one free certificate. After calling this API, the backend will trigger the free certificate application task. You need to complete the domain name verification info configuration within 2 days, then finish certificate authentication.",
|
|
5
5
|
"input": "ApplyFreeCertificateRequest",
|
|
6
6
|
"name": "Applies for a free certificate",
|
|
7
7
|
"output": "ApplyFreeCertificateResponse",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"status": "online"
|
|
37
37
|
},
|
|
38
38
|
"CheckFreeCertificateVerification": {
|
|
39
|
-
"document": "This API is used to verify a free certificate and obtain the application result. If verified, you can query the free certificate information for the corresponding domain name application through this API. If failed to apply, this API will return the corresponding verification failure message.\nThis API is used to check the free certificate application result after triggering the [ApplyFreeCertificate](https://www.tencentcloud.
|
|
39
|
+
"document": "This API is used to verify a free certificate and obtain the application result. If verified, you can query the free certificate information for the corresponding domain name application through this API. If failed to apply, this API will return the corresponding verification failure message.\nThis API is used to check the free certificate application result after triggering the [ApplyFreeCertificate](https://www.tencentcloud.com/document/product/1552/124807?from_cn_redirect=1) . Once the application is successful, you need to configure through the [ModifyHostsCertificate](https://www.tencentcloud.com/document/product/1552/80764?from_cn_redirect=1) to deploy the free certificate to the acceleration domain.",
|
|
40
40
|
"input": "CheckFreeCertificateVerificationRequest",
|
|
41
41
|
"name": "Check free certificate application result",
|
|
42
42
|
"output": "CheckFreeCertificateVerificationResponse",
|
|
@@ -134,7 +134,7 @@
|
|
|
134
134
|
"status": "online"
|
|
135
135
|
},
|
|
136
136
|
"CreateJustInTimeTranscodeTemplate": {
|
|
137
|
-
"document": "JIT transcoding already provides preset transcoding templates to meet most needs. If there are personalized transcoding requirements, you can create custom transcoding templates through this API, with up to 100 custom transcoding templates allowed.\nThis API is used to ensure the consistency of JIT transcoding effect, avoid video output exceptions caused by EO cache or M3U8 sharding template changes during the process, and templates cannot be modified after creation.\nThis API is used to learn about the detailed capacity of JIT transcoding. EdgeOne video instant processing function introduction (https://www.tencentcloud.
|
|
137
|
+
"document": "JIT transcoding already provides preset transcoding templates to meet most needs. If there are personalized transcoding requirements, you can create custom transcoding templates through this API, with up to 100 custom transcoding templates allowed.\nThis API is used to ensure the consistency of JIT transcoding effect, avoid video output exceptions caused by EO cache or M3U8 sharding template changes during the process, and templates cannot be modified after creation.\nThis API is used to learn about the detailed capacity of JIT transcoding. EdgeOne video instant processing function introduction (https://www.tencentcloud.com/document/product/1552/111927?from_cn_redirect=1).",
|
|
138
138
|
"input": "CreateJustInTimeTranscodeTemplateRequest",
|
|
139
139
|
"name": "Create a just-in-time transcoding template",
|
|
140
140
|
"output": "CreateJustInTimeTranscodeTemplateResponse",
|
|
@@ -903,6 +903,13 @@
|
|
|
903
903
|
"output": "DescribeTimingL7CacheDataResponse",
|
|
904
904
|
"status": "online"
|
|
905
905
|
},
|
|
906
|
+
"DescribeTimingL7OriginPullData": {
|
|
907
|
+
"document": "This API is used to query time series data for layer-7 domain services' origin-pull data.",
|
|
908
|
+
"input": "DescribeTimingL7OriginPullDataRequest",
|
|
909
|
+
"name": "Query origin time series data",
|
|
910
|
+
"output": "DescribeTimingL7OriginPullDataResponse",
|
|
911
|
+
"status": "online"
|
|
912
|
+
},
|
|
906
913
|
"DescribeTopL7AnalysisData": {
|
|
907
914
|
"document": "This API is used to query the top N data of the L7 domain name business by specified dimension.\nCreate and bind policy Query instance Reset instance access password.\nThis API is used to query data with a delay of about 10 minutes. It is recommended to pull data from at least 10 minutes before the current time.\nThis API is used to return post-protection traffic request data by default. Users can query defended data in `Filters.mitigatedByWebSecurity`.",
|
|
908
915
|
"input": "DescribeTopL7AnalysisDataRequest",
|
|
@@ -2897,7 +2904,7 @@
|
|
|
2897
2904
|
},
|
|
2898
2905
|
{
|
|
2899
2906
|
"disabled": false,
|
|
2900
|
-
"document": "Specifies the verification method for applying for a free certificate. for detailed verification methods, refer to the [free certificate application documentation](https://www.tencentcloud.
|
|
2907
|
+
"document": "Specifies the verification method for applying for a free certificate. for detailed verification methods, refer to the [free certificate application documentation](https://www.tencentcloud.com/document/product/1552/90437?from_cn_redirect=1). valid values:.\n<li>http_challenge: specifies the file validation mode for http access. verifies by getting file information from the specified URL of the access domain to complete free certificate application.</li>\n<li>dns_challenge: specifies the dns delegation verification method. verifies the free certificate application by adding the designated host record pointing to EdgeOne.</li>\n\nNote: after triggering this api, you need to complete the verification content configuration based on the returned verification information. once configured, you must also verify by calling the <a href = 'https://www.tencentcloud.com/document/product/1552/124806?from_cn_redirect=1'>check free certificate application result</a> api. after verification passes, the application succeeds. once the application is successful, you can call the <a href = 'https://www.tencentcloud.com/document/product/1552/80764?from_cn_redirect=1'>configure domain name certificate</a> API to deploy a free certificate for the current domain name.",
|
|
2901
2908
|
"example": "http_challenge",
|
|
2902
2909
|
"member": "string",
|
|
2903
2910
|
"name": "VerificationMethod",
|
|
@@ -4627,7 +4634,7 @@
|
|
|
4627
4634
|
},
|
|
4628
4635
|
{
|
|
4629
4636
|
"disabled": false,
|
|
4630
|
-
"document": "Acceleration domain name, that domain name used when [applying for free certificate](https://www.tencentcloud.
|
|
4637
|
+
"document": "Acceleration domain name, that domain name used when [applying for free certificate](https://www.tencentcloud.com/document/product/1552/124807?from_cn_redirect=1).",
|
|
4631
4638
|
"example": "qq.com",
|
|
4632
4639
|
"member": "string",
|
|
4633
4640
|
"name": "Domain",
|
|
@@ -13791,7 +13798,7 @@
|
|
|
13791
13798
|
},
|
|
13792
13799
|
{
|
|
13793
13800
|
"disabled": false,
|
|
13794
|
-
"document": "Site ID
|
|
13801
|
+
"document": "Site ID set. this parameter will change from option to required after may 30, 2024. for details, see the notice: [tencent cloud EdgeOne API change notification](https://www.tencentcloud.com/document/product/1145/59980). a maximum of 100 site ids can be imported. use `*` to query all site data under the tencent cloud root account. querying account-level data requires all resource permissions for all sites in this interface.",
|
|
13795
13802
|
"example": "[\"*\"]",
|
|
13796
13803
|
"member": "string",
|
|
13797
13804
|
"name": "ZoneIds",
|
|
@@ -13809,7 +13816,7 @@
|
|
|
13809
13816
|
},
|
|
13810
13817
|
{
|
|
13811
13818
|
"disabled": false,
|
|
13812
|
-
"document": "Filter criteria used when filtering data. valid values refer to the available filter options for L7 access traffic, bandwidth, and request count in the [metric analysis filtering condition description](https://www.tencentcloud.
|
|
13819
|
+
"document": "Filter criteria used when filtering data. valid values refer to the available filter options for L7 access traffic, bandwidth, and request count in the [metric analysis filtering condition description](https://www.tencentcloud.com/document/product/1145/56985#1aaf1150-55a4-4b4d-b103-3a8317ac7945).\nIf needed, limit the site or content identifier by importing the corresponding value in the `ZoneIds.N` parameter.",
|
|
13813
13820
|
"example": "无",
|
|
13814
13821
|
"member": "QueryCondition",
|
|
13815
13822
|
"name": "Filters",
|
|
@@ -13961,6 +13968,98 @@
|
|
|
13961
13968
|
],
|
|
13962
13969
|
"type": "object"
|
|
13963
13970
|
},
|
|
13971
|
+
"DescribeTimingL7OriginPullDataRequest": {
|
|
13972
|
+
"document": "DescribeTimingL7OriginPullData request structure.",
|
|
13973
|
+
"members": [
|
|
13974
|
+
{
|
|
13975
|
+
"disabled": false,
|
|
13976
|
+
"document": "Start time.",
|
|
13977
|
+
"example": "2020-04-29T00:00:00Z",
|
|
13978
|
+
"member": "datetime_iso",
|
|
13979
|
+
"name": "StartTime",
|
|
13980
|
+
"required": true,
|
|
13981
|
+
"type": "string"
|
|
13982
|
+
},
|
|
13983
|
+
{
|
|
13984
|
+
"disabled": false,
|
|
13985
|
+
"document": "End time. The query time range (`EndTime` - `StartTime`) must be less than or equal to 31 days.",
|
|
13986
|
+
"example": "2020-04-30T00:00:00Z",
|
|
13987
|
+
"member": "datetime_iso",
|
|
13988
|
+
"name": "EndTime",
|
|
13989
|
+
"required": true,
|
|
13990
|
+
"type": "string"
|
|
13991
|
+
},
|
|
13992
|
+
{
|
|
13993
|
+
"disabled": false,
|
|
13994
|
+
"document": "Metric list. Valid values:.\n<li>l7Flow_outFlux_hy: specifies the request traffic from the EdgeOne node to the origin server. Unit: byte.</li>\n<li>l7Flow_outBandwidth_hy: specifies the request bandwidth from EdgeOne node to origin server. Unit: bps.</li>\n<li>l7Flow_request_hy: specifies the request count from EdgeOne node to origin server. Unit: times.</li>\n<li>l7Flow_inFlux_hy: specifies the response traffic from the origin server to the EdgeOne node. Unit: byte.</li>\n<li>l7Flow_inBandwidth_hy: specifies the response bandwidth from the origin server to the EdgeOne node. Unit: bps.</li>\n",
|
|
13995
|
+
"example": "[\"l7Flow_outFlux_hy\"]",
|
|
13996
|
+
"member": "string",
|
|
13997
|
+
"name": "MetricNames",
|
|
13998
|
+
"required": true,
|
|
13999
|
+
"type": "list"
|
|
14000
|
+
},
|
|
14001
|
+
{
|
|
14002
|
+
"disabled": false,
|
|
14003
|
+
"document": "Site ID set. This parameter is required. A maximum of 100 zone-ids can be imported. Use `*` to query data for all sites under the Tencent Cloud root account. Querying account-level data requires permissions for all site resources in this interface.",
|
|
14004
|
+
"example": "[\"*\"]",
|
|
14005
|
+
"member": "string",
|
|
14006
|
+
"name": "ZoneIds",
|
|
14007
|
+
"required": true,
|
|
14008
|
+
"type": "list"
|
|
14009
|
+
},
|
|
14010
|
+
{
|
|
14011
|
+
"disabled": false,
|
|
14012
|
+
"document": "Time granularity of the query. Valid values:\n<Li>min: 1 minute.</li><Li>5min: 5 minutes;</li><Li>hour: 1 hour;</li><li>day: 1 day.</li>If this parameter is not input, the granularity will be automatically calculated based on the interval between the start time and end time. Specifically, data will be queried with a granularity of min, 5min, hour, and day respectively when the period is no more than 2 hours, no more than 2 days, no more than 7 days, and over 7 days.",
|
|
14013
|
+
"example": "hour",
|
|
14014
|
+
"member": "string",
|
|
14015
|
+
"name": "Interval",
|
|
14016
|
+
"required": false,
|
|
14017
|
+
"type": "string"
|
|
14018
|
+
},
|
|
14019
|
+
{
|
|
14020
|
+
"disabled": false,
|
|
14021
|
+
"document": "Filter conditions. Details:\n<li>domain: specifies the domain name in client requests. When the domain is onboarded via a wildcard, the recorded value is the wildcard domain itself, not the specific subdomain.</li>",
|
|
14022
|
+
"example": "无",
|
|
14023
|
+
"member": "QueryCondition",
|
|
14024
|
+
"name": "Filters",
|
|
14025
|
+
"required": false,
|
|
14026
|
+
"type": "list"
|
|
14027
|
+
}
|
|
14028
|
+
],
|
|
14029
|
+
"type": "object"
|
|
14030
|
+
},
|
|
14031
|
+
"DescribeTimingL7OriginPullDataResponse": {
|
|
14032
|
+
"document": "DescribeTimingL7OriginPullData response structure.",
|
|
14033
|
+
"members": [
|
|
14034
|
+
{
|
|
14035
|
+
"disabled": false,
|
|
14036
|
+
"document": "Total number of entries in the query result.",
|
|
14037
|
+
"example": "20",
|
|
14038
|
+
"member": "uint64",
|
|
14039
|
+
"name": "TotalCount",
|
|
14040
|
+
"output_required": true,
|
|
14041
|
+
"type": "int",
|
|
14042
|
+
"value_allowed_null": false
|
|
14043
|
+
},
|
|
14044
|
+
{
|
|
14045
|
+
"disabled": false,
|
|
14046
|
+
"document": "Time series data list for origin-pull data.",
|
|
14047
|
+
"example": "无",
|
|
14048
|
+
"member": "TimingDataRecord",
|
|
14049
|
+
"name": "TimingDataRecords",
|
|
14050
|
+
"output_required": true,
|
|
14051
|
+
"type": "list",
|
|
14052
|
+
"value_allowed_null": false
|
|
14053
|
+
},
|
|
14054
|
+
{
|
|
14055
|
+
"document": "The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.",
|
|
14056
|
+
"member": "string",
|
|
14057
|
+
"name": "RequestId",
|
|
14058
|
+
"type": "string"
|
|
14059
|
+
}
|
|
14060
|
+
],
|
|
14061
|
+
"type": "object"
|
|
14062
|
+
},
|
|
13964
14063
|
"DescribeTopL7AnalysisDataRequest": {
|
|
13965
14064
|
"document": "DescribeTopL7AnalysisData request structure.",
|
|
13966
14065
|
"members": [
|
|
@@ -13984,7 +14083,7 @@
|
|
|
13984
14083
|
},
|
|
13985
14084
|
{
|
|
13986
14085
|
"disabled": false,
|
|
13987
|
-
"document": "Queried metric.
|
|
14086
|
+
"document": "Queried metric. Valid values:\n<li> l7Flow_outFlux_country: specifies the l7 EdgeOne response traffic metric counted by the country/region dimension.</li>\n<li> l7Flow_outFlux_province: specifies the l7 EdgeOne response traffic metric counted by the dimension of provinces in chinese mainland.</li>\n<li> l7Flow_outFlux_statusCode: specifies the l7 EdgeOne response traffic metric by status code dimension.</li>\n<li> l7Flow_outFlux_domain: specifies the l7 EdgeOne response traffic metric counted by domain name dimension.</li>\n<li>l7Flow_outFlux_url: specifies the l7 EdgeOne response traffic metric counted by url Path dimension.</li>\n<li> l7Flow_outFlux_resourceType: specifies the l7 EdgeOne response traffic metric counted by resource type dimension.</li>\n<li> l7Flow_outFlux_sip: specifies the l7 EdgeOne response traffic metric counted by the client IP dimension.</li>\n<li>l7Flow_outFlux_referers: specifies the l7 EdgeOne response traffic statistics by Referer dimension.</li>\n<li> l7Flow_outFlux_ua_device: specifies the l7 EdgeOne response traffic metric counted by device type dimension.</li>\n<li> l7Flow_outFlux_ua_browser: specifies the l7 EdgeOne response traffic metric by browser type dimension.</li>\n<li> l7Flow_outFlux_ua_os: specifies the l7 EdgeOne response traffic metric counted by the operating system type dimension.</li>\n<li> l7Flow_outFlux_ua: specifies the l7 EdgeOne response traffic metric by User-Agent dimension statistics.</li>\n<li> l7Flow_request_country: specifies the l7 access request count metric by country/region dimension.</li>\n<li> l7Flow_request_province: specifies the l7 access request count metric by province in the chinese mainland.</li>\n<li> l7Flow_request_statusCode: specifies the l7 access request count metric by status code dimension.</li>\n<li> l7Flow_request_domain: specifies the l7 access request count metric counted by the domain name dimension.</li>\n<li> l7Flow_request_url: specifies the l7 access request count metric counted by url Path dimension. </li>\n<li> l7Flow_request_resourceType: specifies the l7 access request count metric counted by the resource type dimension.</li>\n<li> l7Flow_request_sip: specifies the l7 access request count metric counted by the client IP dimension.</li>\n<li>l7Flow_request_referers: specifies l7 access request count metrics by referer dimension.</li>\n<li> l7Flow_request_ua_device: specifies the l7 access request count metric by device type dimension.</li>\n<li> l7Flow_request_ua_browser: specifies the l7 access request count metric by browser type dimension.</li>\n<li> l7Flow_request_ua_os: specifies the l7 access request count metric counted by the operating system type dimension.</li>\n<li> l7Flow_request_ua: l7 access request count metric counted by the User-Agent dimension.</li>",
|
|
13988
14087
|
"example": "l7Flow_outFlux_country",
|
|
13989
14088
|
"member": "string",
|
|
13990
14089
|
"name": "MetricName",
|
|
@@ -13993,11 +14092,11 @@
|
|
|
13993
14092
|
},
|
|
13994
14093
|
{
|
|
13995
14094
|
"disabled": false,
|
|
13996
|
-
"document": "Site ID set. this parameter will change from option to required after may 30, 2024. for details, see the notice: [tencent cloud EdgeOne API change notification](https://www.tencentcloud.
|
|
14095
|
+
"document": "Site ID set. this parameter will change from option to required after may 30, 2024. for details, see the notice: [tencent cloud EdgeOne API change notification](https://www.tencentcloud.com/document/product/1552/104902?from_cn_redirect=1). a maximum of 100 site ids can be imported. use `*` to query all site data under the tencent cloud root account. querying account-level data requires all resource permissions for all sites in this interface.",
|
|
13997
14096
|
"example": "[\"*\"]",
|
|
13998
14097
|
"member": "string",
|
|
13999
14098
|
"name": "ZoneIds",
|
|
14000
|
-
"required":
|
|
14099
|
+
"required": true,
|
|
14001
14100
|
"type": "list"
|
|
14002
14101
|
},
|
|
14003
14102
|
{
|
|
@@ -20050,7 +20149,7 @@
|
|
|
20050
20149
|
},
|
|
20051
20150
|
{
|
|
20052
20151
|
"disabled": false,
|
|
20053
|
-
"document": "Configures the server certificate mode. valid values:.\n\n- disable: without configuring server certificate.\n- eofreecert: specifies to apply for a free certificate through automatic validation and deploy it. for verification methods, see [free certificate application supported verification methods](https://www.tencentcloud.
|
|
20152
|
+
"document": "Configures the server certificate mode. valid values:.\n\n- disable: without configuring server certificate.\n- eofreecert: specifies to apply for a free certificate through automatic validation and deploy it. for verification methods, see [free certificate application supported verification methods](https://www.tencentcloud.com/document/product/1552/90437?from_cn_redirect=1).\n - In ns or DNSPod hosting access mode, free certificates can only be applied for via automatic validation.\n - When a free certificate application fails, it can cause deployment failure. you can obtain the failure reason through the <a href = 'https://www.tencentcloud.com/document/product/1552/124806?from_cn_redirect=1)'>check free certificate application result</a> .\n- eofreecert_manual: specifies the deployment of free certificates applied through DNS delegation verification or file verification. before deploying a free certificate, you need to trigger the [apply for free certificate](https://www.tencentcloud.com/document/product/1552/124807?from_cn_redirect=1)) api to apply for a free certificate. once the application is successful, you can use this enumeration value to deploy the free certificate.\nNote: when deploying a free certificate, ensure a successful application for a free certificate already exists. you can check whether a successful application for a free certificate already exists through the <a href = 'https://www.tencentcloud.com/document/product/1552/124806?from_cn_redirect=1)'>check free certificate application result</a> api.\n- sslcert: specifies the configuration of the managed service side certificate.",
|
|
20054
20153
|
"example": "eofreecert",
|
|
20055
20154
|
"member": "string",
|
|
20056
20155
|
"name": "Mode",
|
|
@@ -20086,7 +20185,7 @@
|
|
|
20086
20185
|
},
|
|
20087
20186
|
{
|
|
20088
20187
|
"disabled": false,
|
|
20089
|
-
"document": "Specifies the certificate carried during EO node origin-pull for origin-pull mutual authentication handshake, off by default. leave blank to indicate retaining the original configuration. this configuration is currently in closed beta testing for the allowlist feature. if you need to use it, please contact us (https://www.tencentcloud.
|
|
20188
|
+
"document": "Specifies the certificate carried during EO node origin-pull for origin-pull mutual authentication handshake, off by default. leave blank to indicate retaining the original configuration. this configuration is currently in closed beta testing for the allowlist feature. if you need to use it, please contact us (https://www.tencentcloud.com/online?from_cn_redirect=1-service).",
|
|
20090
20189
|
"example": "无",
|
|
20091
20190
|
"member": "UpstreamCertInfo",
|
|
20092
20191
|
"name": "UpstreamCertInfo",
|
|
@@ -1308,6 +1308,14 @@
|
|
|
1308
1308
|
"title": "Querying the Time Series Traffic Data by Specified Status Code"
|
|
1309
1309
|
}
|
|
1310
1310
|
],
|
|
1311
|
+
"DescribeTimingL7OriginPullData": [
|
|
1312
|
+
{
|
|
1313
|
+
"document": "This example shows you how to query the number of origin-pull requests for layer-7 domain services under specified site ID zone-2ntf1u8utpmz from 2025-07-01 00:00:00 to 2025-07-15 00:00:00 with a query time granularity of day.",
|
|
1314
|
+
"input": "POST / HTTP/1.1\nHost: teo.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: DescribeTimingL7OriginPullData\n<Common request parameters>\n\n{\n \"StartTime\": \"2025-07-01T00:00:00+08:00\",\n \"EndTime\": \"2025-07-15T00:00:00+08:00\",\n \"Interval\": \"day\",\n \"MetricNames\": [\n \"l7Flow_request_hy\"\n ],\n \"ZoneIds\": [\n \"zone-2ntf1u8utpmz\"\n ]\n}",
|
|
1315
|
+
"output": "{\n \"Response\": {\n \"RequestId\": \"7cc73e86-092b-4aa2-b28a-c9c338834926\",\n \"TimingDataRecords\": [\n {\n \"TypeKey\": \"251008840\",\n \"TypeValue\": [\n {\n \"Avg\": 1714316,\n \"Detail\": [\n {\n \"Timestamp\": 1751299200,\n \"Value\": 0\n },\n {\n \"Timestamp\": 1751385600,\n \"Value\": 0\n },\n {\n \"Timestamp\": 1751472000,\n \"Value\": 1471972\n },\n {\n \"Timestamp\": 1751558400,\n \"Value\": 2824464\n },\n {\n \"Timestamp\": 1751644800,\n \"Value\": 2815290\n },\n {\n \"Timestamp\": 1751731200,\n \"Value\": 2814852\n },\n {\n \"Timestamp\": 1751817600,\n \"Value\": 2815244\n },\n {\n \"Timestamp\": 1751904000,\n \"Value\": 11147558\n },\n {\n \"Timestamp\": 1751990400,\n \"Value\": 6\n },\n {\n \"Timestamp\": 1752076800,\n \"Value\": 0\n },\n {\n \"Timestamp\": 1752163200,\n \"Value\": 0\n },\n {\n \"Timestamp\": 1752249600,\n \"Value\": 0\n },\n {\n \"Timestamp\": 1752336000,\n \"Value\": 0\n },\n {\n \"Timestamp\": 1752422400,\n \"Value\": 111050\n }\n ],\n \"Max\": 11147558,\n \"MetricName\": \"l7Flow_request_hy\",\n \"Sum\": 24000436\n }\n ]\n }\n ],\n \"TotalCount\": 1\n }\n}",
|
|
1316
|
+
"title": "Querying Time Series Data for Origin Analysis"
|
|
1317
|
+
}
|
|
1318
|
+
],
|
|
1311
1319
|
"DescribeTopL7AnalysisData": [
|
|
1312
1320
|
{
|
|
1313
1321
|
"document": "This example shows you how to query the traffic data of the top URL path under a specific HTTP protocol version (HTTP/1.0 or HTTP/1.1).",
|
tccli/services/tke/tke_client.py
CHANGED
|
@@ -2824,6 +2824,61 @@ def doAddVpcCniSubnets(args, parsed_globals):
|
|
|
2824
2824
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
2825
2825
|
|
|
2826
2826
|
|
|
2827
|
+
def doDisableControlPlaneLogs(args, parsed_globals):
|
|
2828
|
+
g_param = parse_global_arg(parsed_globals)
|
|
2829
|
+
|
|
2830
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
|
2831
|
+
cred = credential.CVMRoleCredential()
|
|
2832
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
|
2833
|
+
cred = credential.STSAssumeRoleCredential(
|
|
2834
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
|
2835
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
|
2836
|
+
)
|
|
2837
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) \
|
|
2838
|
+
and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) \
|
|
2839
|
+
and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) \
|
|
2840
|
+
and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
|
2841
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
|
2842
|
+
else:
|
|
2843
|
+
cred = credential.Credential(
|
|
2844
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
|
2845
|
+
)
|
|
2846
|
+
http_profile = HttpProfile(
|
|
2847
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
|
2848
|
+
reqMethod="POST",
|
|
2849
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
|
2850
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
|
2851
|
+
)
|
|
2852
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="TC3-HMAC-SHA256")
|
|
2853
|
+
if g_param[OptionsDefine.Language]:
|
|
2854
|
+
profile.language = g_param[OptionsDefine.Language]
|
|
2855
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
|
2856
|
+
client = mod.TkeClient(cred, g_param[OptionsDefine.Region], profile)
|
|
2857
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
|
2858
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
|
2859
|
+
model = models.DisableControlPlaneLogsRequest()
|
|
2860
|
+
model.from_json_string(json.dumps(args))
|
|
2861
|
+
start_time = time.time()
|
|
2862
|
+
while True:
|
|
2863
|
+
rsp = client.DisableControlPlaneLogs(model)
|
|
2864
|
+
result = rsp.to_json_string()
|
|
2865
|
+
try:
|
|
2866
|
+
json_obj = json.loads(result)
|
|
2867
|
+
except TypeError as e:
|
|
2868
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
|
2869
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
|
2870
|
+
break
|
|
2871
|
+
cur_time = time.time()
|
|
2872
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
|
2873
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
|
2874
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
|
2875
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
|
2876
|
+
else:
|
|
2877
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
|
2878
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
|
2879
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
2880
|
+
|
|
2881
|
+
|
|
2827
2882
|
def doDescribeExistedInstances(args, parsed_globals):
|
|
2828
2883
|
g_param = parse_global_arg(parsed_globals)
|
|
2829
2884
|
|
|
@@ -6124,6 +6179,61 @@ def doDescribeClusterRoutes(args, parsed_globals):
|
|
|
6124
6179
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
6125
6180
|
|
|
6126
6181
|
|
|
6182
|
+
def doEnableControlPlaneLogs(args, parsed_globals):
|
|
6183
|
+
g_param = parse_global_arg(parsed_globals)
|
|
6184
|
+
|
|
6185
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
|
6186
|
+
cred = credential.CVMRoleCredential()
|
|
6187
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
|
6188
|
+
cred = credential.STSAssumeRoleCredential(
|
|
6189
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
|
6190
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
|
6191
|
+
)
|
|
6192
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) \
|
|
6193
|
+
and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) \
|
|
6194
|
+
and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) \
|
|
6195
|
+
and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
|
6196
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
|
6197
|
+
else:
|
|
6198
|
+
cred = credential.Credential(
|
|
6199
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
|
6200
|
+
)
|
|
6201
|
+
http_profile = HttpProfile(
|
|
6202
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
|
6203
|
+
reqMethod="POST",
|
|
6204
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
|
6205
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
|
6206
|
+
)
|
|
6207
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="TC3-HMAC-SHA256")
|
|
6208
|
+
if g_param[OptionsDefine.Language]:
|
|
6209
|
+
profile.language = g_param[OptionsDefine.Language]
|
|
6210
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
|
6211
|
+
client = mod.TkeClient(cred, g_param[OptionsDefine.Region], profile)
|
|
6212
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
|
6213
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
|
6214
|
+
model = models.EnableControlPlaneLogsRequest()
|
|
6215
|
+
model.from_json_string(json.dumps(args))
|
|
6216
|
+
start_time = time.time()
|
|
6217
|
+
while True:
|
|
6218
|
+
rsp = client.EnableControlPlaneLogs(model)
|
|
6219
|
+
result = rsp.to_json_string()
|
|
6220
|
+
try:
|
|
6221
|
+
json_obj = json.loads(result)
|
|
6222
|
+
except TypeError as e:
|
|
6223
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
|
6224
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
|
6225
|
+
break
|
|
6226
|
+
cur_time = time.time()
|
|
6227
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
|
6228
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
|
6229
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
|
6230
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
|
6231
|
+
else:
|
|
6232
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
|
6233
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
|
6234
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
6235
|
+
|
|
6236
|
+
|
|
6127
6237
|
def doModifyNodePoolInstanceTypes(args, parsed_globals):
|
|
6128
6238
|
g_param = parse_global_arg(parsed_globals)
|
|
6129
6239
|
|
|
@@ -6234,6 +6344,61 @@ def doCheckInstancesUpgradeAble(args, parsed_globals):
|
|
|
6234
6344
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
6235
6345
|
|
|
6236
6346
|
|
|
6347
|
+
def doDescribeControlPlaneLogs(args, parsed_globals):
|
|
6348
|
+
g_param = parse_global_arg(parsed_globals)
|
|
6349
|
+
|
|
6350
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
|
6351
|
+
cred = credential.CVMRoleCredential()
|
|
6352
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
|
6353
|
+
cred = credential.STSAssumeRoleCredential(
|
|
6354
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
|
6355
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
|
6356
|
+
)
|
|
6357
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) \
|
|
6358
|
+
and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) \
|
|
6359
|
+
and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) \
|
|
6360
|
+
and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
|
6361
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
|
6362
|
+
else:
|
|
6363
|
+
cred = credential.Credential(
|
|
6364
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
|
6365
|
+
)
|
|
6366
|
+
http_profile = HttpProfile(
|
|
6367
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
|
6368
|
+
reqMethod="POST",
|
|
6369
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
|
6370
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
|
6371
|
+
)
|
|
6372
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="TC3-HMAC-SHA256")
|
|
6373
|
+
if g_param[OptionsDefine.Language]:
|
|
6374
|
+
profile.language = g_param[OptionsDefine.Language]
|
|
6375
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
|
6376
|
+
client = mod.TkeClient(cred, g_param[OptionsDefine.Region], profile)
|
|
6377
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
|
6378
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
|
6379
|
+
model = models.DescribeControlPlaneLogsRequest()
|
|
6380
|
+
model.from_json_string(json.dumps(args))
|
|
6381
|
+
start_time = time.time()
|
|
6382
|
+
while True:
|
|
6383
|
+
rsp = client.DescribeControlPlaneLogs(model)
|
|
6384
|
+
result = rsp.to_json_string()
|
|
6385
|
+
try:
|
|
6386
|
+
json_obj = json.loads(result)
|
|
6387
|
+
except TypeError as e:
|
|
6388
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
|
6389
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
|
6390
|
+
break
|
|
6391
|
+
cur_time = time.time()
|
|
6392
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
|
6393
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
|
6394
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
|
6395
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
|
6396
|
+
else:
|
|
6397
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
|
6398
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
|
6399
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
|
6400
|
+
|
|
6401
|
+
|
|
6237
6402
|
def doDeleteNodePool(args, parsed_globals):
|
|
6238
6403
|
g_param = parse_global_arg(parsed_globals)
|
|
6239
6404
|
|
|
@@ -7673,6 +7838,7 @@ ACTION_MAP = {
|
|
|
7673
7838
|
"DeleteClusterAsGroups": doDeleteClusterAsGroups,
|
|
7674
7839
|
"DeleteClusterRoute": doDeleteClusterRoute,
|
|
7675
7840
|
"AddVpcCniSubnets": doAddVpcCniSubnets,
|
|
7841
|
+
"DisableControlPlaneLogs": doDisableControlPlaneLogs,
|
|
7676
7842
|
"DescribeExistedInstances": doDescribeExistedInstances,
|
|
7677
7843
|
"DescribeClusterNodePools": doDescribeClusterNodePools,
|
|
7678
7844
|
"DescribeTKEEdgeClusterCredential": doDescribeTKEEdgeClusterCredential,
|
|
@@ -7733,8 +7899,10 @@ ACTION_MAP = {
|
|
|
7733
7899
|
"DescribeClusterEndpoints": doDescribeClusterEndpoints,
|
|
7734
7900
|
"ModifyClusterEndpointSP": doModifyClusterEndpointSP,
|
|
7735
7901
|
"DescribeClusterRoutes": doDescribeClusterRoutes,
|
|
7902
|
+
"EnableControlPlaneLogs": doEnableControlPlaneLogs,
|
|
7736
7903
|
"ModifyNodePoolInstanceTypes": doModifyNodePoolInstanceTypes,
|
|
7737
7904
|
"CheckInstancesUpgradeAble": doCheckInstancesUpgradeAble,
|
|
7905
|
+
"DescribeControlPlaneLogs": doDescribeControlPlaneLogs,
|
|
7738
7906
|
"DeleteNodePool": doDeleteNodePool,
|
|
7739
7907
|
"DescribeHealthCheckPolicies": doDescribeHealthCheckPolicies,
|
|
7740
7908
|
"DescribeImages": doDescribeImages,
|