tccli 3.0.1352.1__py2.py3-none-any.whl → 3.0.1353.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/aiart/v20221229/api.json +3 -3
- tccli/services/apm/v20210622/api.json +1 -1
- tccli/services/cdn/v20180606/api.json +0 -3
- tccli/services/cdn/v20180606/examples.json +2 -2
- tccli/services/cfg/v20210820/api.json +11 -0
- tccli/services/cfs/v20190719/api.json +46 -0
- tccli/services/csip/v20221121/api.json +21 -3
- tccli/services/csip/v20221121/examples.json +1 -1
- tccli/services/eb/v20210416/api.json +17 -8
- tccli/services/eb/v20210416/examples.json +1 -1
- tccli/services/ess/v20201111/api.json +1 -1
- tccli/services/iai/v20180301/api.json +143 -135
- tccli/services/iai/v20180301/examples.json +18 -12
- tccli/services/iai/v20200303/api.json +4 -4
- tccli/services/igtm/v20231024/api.json +139 -139
- tccli/services/iotvideo/v20191126/api.json +1 -1
- tccli/services/iotvideo/v20201215/api.json +1 -1
- tccli/services/iotvideo/v20211125/api.json +1 -1
- tccli/services/lighthouse/v20200324/api.json +10 -0
- tccli/services/lke/v20231130/api.json +2 -2
- tccli/services/lkeap/v20240522/api.json +3 -3
- tccli/services/monitor/v20180724/api.json +7 -7
- tccli/services/monitor/v20180724/examples.json +2 -2
- tccli/services/tcbr/v20220217/api.json +10 -0
- tccli/services/tke/v20180525/api.json +49 -1
- tccli/services/trro/v20220325/api.json +1 -1
- tccli/services/trtc/trtc_client.py +459 -35
- tccli/services/trtc/v20190722/api.json +1068 -81
- tccli/services/trtc/v20190722/examples.json +64 -0
- tccli/services/tts/v20190823/api.json +1 -1
- tccli/services/vod/v20180717/examples.json +17 -17
- tccli/services/wedata/v20210820/api.json +501 -3
- tccli/services/wedata/v20210820/examples.json +86 -0
- tccli/services/wedata/wedata_client.py +440 -69
- {tccli-3.0.1352.1.dist-info → tccli-3.0.1353.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1352.1.dist-info → tccli-3.0.1353.1.dist-info}/RECORD +40 -40
- {tccli-3.0.1352.1.dist-info → tccli-3.0.1353.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1352.1.dist-info → tccli-3.0.1353.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1352.1.dist-info → tccli-3.0.1353.1.dist-info}/license_files/LICENSE +0 -0
@@ -1785,6 +1785,58 @@ def doResumeIntegrationTask(args, parsed_globals):
|
|
1785
1785
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1786
1786
|
|
1787
1787
|
|
1788
|
+
def doCreateRule(args, parsed_globals):
|
1789
|
+
g_param = parse_global_arg(parsed_globals)
|
1790
|
+
|
1791
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
1792
|
+
cred = credential.CVMRoleCredential()
|
1793
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1794
|
+
cred = credential.STSAssumeRoleCredential(
|
1795
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1796
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1797
|
+
)
|
1798
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1799
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
1800
|
+
else:
|
1801
|
+
cred = credential.Credential(
|
1802
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
1803
|
+
)
|
1804
|
+
http_profile = HttpProfile(
|
1805
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
1806
|
+
reqMethod="POST",
|
1807
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
1808
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
1809
|
+
)
|
1810
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
1811
|
+
if g_param[OptionsDefine.Language]:
|
1812
|
+
profile.language = g_param[OptionsDefine.Language]
|
1813
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
1814
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
1815
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
1816
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
1817
|
+
model = models.CreateRuleRequest()
|
1818
|
+
model.from_json_string(json.dumps(args))
|
1819
|
+
start_time = time.time()
|
1820
|
+
while True:
|
1821
|
+
rsp = client.CreateRule(model)
|
1822
|
+
result = rsp.to_json_string()
|
1823
|
+
try:
|
1824
|
+
json_obj = json.loads(result)
|
1825
|
+
except TypeError as e:
|
1826
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
1827
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
1828
|
+
break
|
1829
|
+
cur_time = time.time()
|
1830
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
1831
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
1832
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
1833
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
1834
|
+
else:
|
1835
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
1836
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
1837
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1838
|
+
|
1839
|
+
|
1788
1840
|
def doDescribeInstanceLogList(args, parsed_globals):
|
1789
1841
|
g_param = parse_global_arg(parsed_globals)
|
1790
1842
|
|
@@ -1993,6 +2045,58 @@ def doCreateCustomFunction(args, parsed_globals):
|
|
1993
2045
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1994
2046
|
|
1995
2047
|
|
2048
|
+
def doBatchCreateTaskVersionAsync(args, parsed_globals):
|
2049
|
+
g_param = parse_global_arg(parsed_globals)
|
2050
|
+
|
2051
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
2052
|
+
cred = credential.CVMRoleCredential()
|
2053
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2054
|
+
cred = credential.STSAssumeRoleCredential(
|
2055
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2056
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2057
|
+
)
|
2058
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2059
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
2060
|
+
else:
|
2061
|
+
cred = credential.Credential(
|
2062
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
2063
|
+
)
|
2064
|
+
http_profile = HttpProfile(
|
2065
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
2066
|
+
reqMethod="POST",
|
2067
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
2068
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
2069
|
+
)
|
2070
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
2071
|
+
if g_param[OptionsDefine.Language]:
|
2072
|
+
profile.language = g_param[OptionsDefine.Language]
|
2073
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
2074
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
2075
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
2076
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
2077
|
+
model = models.BatchCreateTaskVersionAsyncRequest()
|
2078
|
+
model.from_json_string(json.dumps(args))
|
2079
|
+
start_time = time.time()
|
2080
|
+
while True:
|
2081
|
+
rsp = client.BatchCreateTaskVersionAsync(model)
|
2082
|
+
result = rsp.to_json_string()
|
2083
|
+
try:
|
2084
|
+
json_obj = json.loads(result)
|
2085
|
+
except TypeError as e:
|
2086
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
2087
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
2088
|
+
break
|
2089
|
+
cur_time = time.time()
|
2090
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
2091
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
2092
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
2093
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
2094
|
+
else:
|
2095
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
2096
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
2097
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2098
|
+
|
2099
|
+
|
1996
2100
|
def doDescribeExecStrategy(args, parsed_globals):
|
1997
2101
|
g_param = parse_global_arg(parsed_globals)
|
1998
2102
|
|
@@ -3293,7 +3397,7 @@ def doGetCosToken(args, parsed_globals):
|
|
3293
3397
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
3294
3398
|
|
3295
3399
|
|
3296
|
-
def
|
3400
|
+
def doEnableProject(args, parsed_globals):
|
3297
3401
|
g_param = parse_global_arg(parsed_globals)
|
3298
3402
|
|
3299
3403
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -3322,11 +3426,11 @@ def doCreateRule(args, parsed_globals):
|
|
3322
3426
|
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
3323
3427
|
client._sdkVersion += ("_CLI_" + __version__)
|
3324
3428
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
3325
|
-
model = models.
|
3429
|
+
model = models.EnableProjectRequest()
|
3326
3430
|
model.from_json_string(json.dumps(args))
|
3327
3431
|
start_time = time.time()
|
3328
3432
|
while True:
|
3329
|
-
rsp = client.
|
3433
|
+
rsp = client.EnableProject(model)
|
3330
3434
|
result = rsp.to_json_string()
|
3331
3435
|
try:
|
3332
3436
|
json_obj = json.loads(result)
|
@@ -5009,6 +5113,58 @@ def doBatchStartIntegrationTasks(args, parsed_globals):
|
|
5009
5113
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
5010
5114
|
|
5011
5115
|
|
5116
|
+
def doDisableProject(args, parsed_globals):
|
5117
|
+
g_param = parse_global_arg(parsed_globals)
|
5118
|
+
|
5119
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
5120
|
+
cred = credential.CVMRoleCredential()
|
5121
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5122
|
+
cred = credential.STSAssumeRoleCredential(
|
5123
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5124
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5125
|
+
)
|
5126
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5127
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
5128
|
+
else:
|
5129
|
+
cred = credential.Credential(
|
5130
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
5131
|
+
)
|
5132
|
+
http_profile = HttpProfile(
|
5133
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
5134
|
+
reqMethod="POST",
|
5135
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
5136
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
5137
|
+
)
|
5138
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
5139
|
+
if g_param[OptionsDefine.Language]:
|
5140
|
+
profile.language = g_param[OptionsDefine.Language]
|
5141
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
5142
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
5143
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
5144
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
5145
|
+
model = models.DisableProjectRequest()
|
5146
|
+
model.from_json_string(json.dumps(args))
|
5147
|
+
start_time = time.time()
|
5148
|
+
while True:
|
5149
|
+
rsp = client.DisableProject(model)
|
5150
|
+
result = rsp.to_json_string()
|
5151
|
+
try:
|
5152
|
+
json_obj = json.loads(result)
|
5153
|
+
except TypeError as e:
|
5154
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
5155
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
5156
|
+
break
|
5157
|
+
cur_time = time.time()
|
5158
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
5159
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
5160
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
5161
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
5162
|
+
else:
|
5163
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
5164
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
5165
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
5166
|
+
|
5167
|
+
|
5012
5168
|
def doModifyTaskName(args, parsed_globals):
|
5013
5169
|
g_param = parse_global_arg(parsed_globals)
|
5014
5170
|
|
@@ -5581,6 +5737,58 @@ def doDescribeSchedulerTaskCntByStatus(args, parsed_globals):
|
|
5581
5737
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
5582
5738
|
|
5583
5739
|
|
5740
|
+
def doBindProjectExecutorResource(args, parsed_globals):
|
5741
|
+
g_param = parse_global_arg(parsed_globals)
|
5742
|
+
|
5743
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
5744
|
+
cred = credential.CVMRoleCredential()
|
5745
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5746
|
+
cred = credential.STSAssumeRoleCredential(
|
5747
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5748
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5749
|
+
)
|
5750
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5751
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
5752
|
+
else:
|
5753
|
+
cred = credential.Credential(
|
5754
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
5755
|
+
)
|
5756
|
+
http_profile = HttpProfile(
|
5757
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
5758
|
+
reqMethod="POST",
|
5759
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
5760
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
5761
|
+
)
|
5762
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
5763
|
+
if g_param[OptionsDefine.Language]:
|
5764
|
+
profile.language = g_param[OptionsDefine.Language]
|
5765
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
5766
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
5767
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
5768
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
5769
|
+
model = models.BindProjectExecutorResourceRequest()
|
5770
|
+
model.from_json_string(json.dumps(args))
|
5771
|
+
start_time = time.time()
|
5772
|
+
while True:
|
5773
|
+
rsp = client.BindProjectExecutorResource(model)
|
5774
|
+
result = rsp.to_json_string()
|
5775
|
+
try:
|
5776
|
+
json_obj = json.loads(result)
|
5777
|
+
except TypeError as e:
|
5778
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
5779
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
5780
|
+
break
|
5781
|
+
cur_time = time.time()
|
5782
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
5783
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
5784
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
5785
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
5786
|
+
else:
|
5787
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
5788
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
5789
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
5790
|
+
|
5791
|
+
|
5584
5792
|
def doModifyWorkflowSchedule(args, parsed_globals):
|
5585
5793
|
g_param = parse_global_arg(parsed_globals)
|
5586
5794
|
|
@@ -8181,6 +8389,58 @@ def doDescribeTableScoreTrend(args, parsed_globals):
|
|
8181
8389
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
8182
8390
|
|
8183
8391
|
|
8392
|
+
def doCreateBaseProject(args, parsed_globals):
|
8393
|
+
g_param = parse_global_arg(parsed_globals)
|
8394
|
+
|
8395
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
8396
|
+
cred = credential.CVMRoleCredential()
|
8397
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
8398
|
+
cred = credential.STSAssumeRoleCredential(
|
8399
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
8400
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
8401
|
+
)
|
8402
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
8403
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
8404
|
+
else:
|
8405
|
+
cred = credential.Credential(
|
8406
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
8407
|
+
)
|
8408
|
+
http_profile = HttpProfile(
|
8409
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
8410
|
+
reqMethod="POST",
|
8411
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
8412
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
8413
|
+
)
|
8414
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
8415
|
+
if g_param[OptionsDefine.Language]:
|
8416
|
+
profile.language = g_param[OptionsDefine.Language]
|
8417
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
8418
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
8419
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
8420
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
8421
|
+
model = models.CreateBaseProjectRequest()
|
8422
|
+
model.from_json_string(json.dumps(args))
|
8423
|
+
start_time = time.time()
|
8424
|
+
while True:
|
8425
|
+
rsp = client.CreateBaseProject(model)
|
8426
|
+
result = rsp.to_json_string()
|
8427
|
+
try:
|
8428
|
+
json_obj = json.loads(result)
|
8429
|
+
except TypeError as e:
|
8430
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
8431
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
8432
|
+
break
|
8433
|
+
cur_time = time.time()
|
8434
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
8435
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
8436
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
8437
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
8438
|
+
else:
|
8439
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
8440
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
8441
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
8442
|
+
|
8443
|
+
|
8184
8444
|
def doDescribeTableQualityDetails(args, parsed_globals):
|
8185
8445
|
g_param = parse_global_arg(parsed_globals)
|
8186
8446
|
|
@@ -8805,7 +9065,7 @@ def doUploadResource(args, parsed_globals):
|
|
8805
9065
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
8806
9066
|
|
8807
9067
|
|
8808
|
-
def
|
9068
|
+
def doModifyProject(args, parsed_globals):
|
8809
9069
|
g_param = parse_global_arg(parsed_globals)
|
8810
9070
|
|
8811
9071
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -8834,11 +9094,11 @@ def doBatchCreateTaskVersionAsync(args, parsed_globals):
|
|
8834
9094
|
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
8835
9095
|
client._sdkVersion += ("_CLI_" + __version__)
|
8836
9096
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
8837
|
-
model = models.
|
9097
|
+
model = models.ModifyProjectRequest()
|
8838
9098
|
model.from_json_string(json.dumps(args))
|
8839
9099
|
start_time = time.time()
|
8840
9100
|
while True:
|
8841
|
-
rsp = client.
|
9101
|
+
rsp = client.ModifyProject(model)
|
8842
9102
|
result = rsp.to_json_string()
|
8843
9103
|
try:
|
8844
9104
|
json_obj = json.loads(result)
|
@@ -8909,7 +9169,7 @@ def doDeleteProjectUsers(args, parsed_globals):
|
|
8909
9169
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
8910
9170
|
|
8911
9171
|
|
8912
|
-
def
|
9172
|
+
def doDescribeRelatedTasksByTaskId(args, parsed_globals):
|
8913
9173
|
g_param = parse_global_arg(parsed_globals)
|
8914
9174
|
|
8915
9175
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -8938,11 +9198,11 @@ def doGetOfflineDIInstanceList(args, parsed_globals):
|
|
8938
9198
|
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
8939
9199
|
client._sdkVersion += ("_CLI_" + __version__)
|
8940
9200
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
8941
|
-
model = models.
|
9201
|
+
model = models.DescribeRelatedTasksByTaskIdRequest()
|
8942
9202
|
model.from_json_string(json.dumps(args))
|
8943
9203
|
start_time = time.time()
|
8944
9204
|
while True:
|
8945
|
-
rsp = client.
|
9205
|
+
rsp = client.DescribeRelatedTasksByTaskId(model)
|
8946
9206
|
result = rsp.to_json_string()
|
8947
9207
|
try:
|
8948
9208
|
json_obj = json.loads(result)
|
@@ -9845,6 +10105,58 @@ def doModifyMonitorStatus(args, parsed_globals):
|
|
9845
10105
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
9846
10106
|
|
9847
10107
|
|
10108
|
+
def doDeleteTaskLineage(args, parsed_globals):
|
10109
|
+
g_param = parse_global_arg(parsed_globals)
|
10110
|
+
|
10111
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
10112
|
+
cred = credential.CVMRoleCredential()
|
10113
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
10114
|
+
cred = credential.STSAssumeRoleCredential(
|
10115
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
10116
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
10117
|
+
)
|
10118
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
10119
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
10120
|
+
else:
|
10121
|
+
cred = credential.Credential(
|
10122
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
10123
|
+
)
|
10124
|
+
http_profile = HttpProfile(
|
10125
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
10126
|
+
reqMethod="POST",
|
10127
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
10128
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
10129
|
+
)
|
10130
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
10131
|
+
if g_param[OptionsDefine.Language]:
|
10132
|
+
profile.language = g_param[OptionsDefine.Language]
|
10133
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
10134
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
10135
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
10136
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
10137
|
+
model = models.DeleteTaskLineageRequest()
|
10138
|
+
model.from_json_string(json.dumps(args))
|
10139
|
+
start_time = time.time()
|
10140
|
+
while True:
|
10141
|
+
rsp = client.DeleteTaskLineage(model)
|
10142
|
+
result = rsp.to_json_string()
|
10143
|
+
try:
|
10144
|
+
json_obj = json.loads(result)
|
10145
|
+
except TypeError as e:
|
10146
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
10147
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
10148
|
+
break
|
10149
|
+
cur_time = time.time()
|
10150
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
10151
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
10152
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
10153
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
10154
|
+
else:
|
10155
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
10156
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
10157
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
10158
|
+
|
10159
|
+
|
9848
10160
|
def doDescribeAllByFolderNew(args, parsed_globals):
|
9849
10161
|
g_param = parse_global_arg(parsed_globals)
|
9850
10162
|
|
@@ -10001,6 +10313,58 @@ def doUpdateWorkflowInfo(args, parsed_globals):
|
|
10001
10313
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
10002
10314
|
|
10003
10315
|
|
10316
|
+
def doUnboundProjectExecutorResource(args, parsed_globals):
|
10317
|
+
g_param = parse_global_arg(parsed_globals)
|
10318
|
+
|
10319
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
10320
|
+
cred = credential.CVMRoleCredential()
|
10321
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
10322
|
+
cred = credential.STSAssumeRoleCredential(
|
10323
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
10324
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
10325
|
+
)
|
10326
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
10327
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
10328
|
+
else:
|
10329
|
+
cred = credential.Credential(
|
10330
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
10331
|
+
)
|
10332
|
+
http_profile = HttpProfile(
|
10333
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
10334
|
+
reqMethod="POST",
|
10335
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
10336
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
10337
|
+
)
|
10338
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
10339
|
+
if g_param[OptionsDefine.Language]:
|
10340
|
+
profile.language = g_param[OptionsDefine.Language]
|
10341
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
10342
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
10343
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
10344
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
10345
|
+
model = models.UnboundProjectExecutorResourceRequest()
|
10346
|
+
model.from_json_string(json.dumps(args))
|
10347
|
+
start_time = time.time()
|
10348
|
+
while True:
|
10349
|
+
rsp = client.UnboundProjectExecutorResource(model)
|
10350
|
+
result = rsp.to_json_string()
|
10351
|
+
try:
|
10352
|
+
json_obj = json.loads(result)
|
10353
|
+
except TypeError as e:
|
10354
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
10355
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
10356
|
+
break
|
10357
|
+
cur_time = time.time()
|
10358
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
10359
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
10360
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
10361
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
10362
|
+
else:
|
10363
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
10364
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
10365
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
10366
|
+
|
10367
|
+
|
10004
10368
|
def doDescribeTableLineage(args, parsed_globals):
|
10005
10369
|
g_param = parse_global_arg(parsed_globals)
|
10006
10370
|
|
@@ -10105,7 +10469,7 @@ def doDescribeEventCases(args, parsed_globals):
|
|
10105
10469
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
10106
10470
|
|
10107
10471
|
|
10108
|
-
def
|
10472
|
+
def doDeleteFile(args, parsed_globals):
|
10109
10473
|
g_param = parse_global_arg(parsed_globals)
|
10110
10474
|
|
10111
10475
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -10134,11 +10498,11 @@ def doDescribeRelatedTasksByTaskId(args, parsed_globals):
|
|
10134
10498
|
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
10135
10499
|
client._sdkVersion += ("_CLI_" + __version__)
|
10136
10500
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
10137
|
-
model = models.
|
10501
|
+
model = models.DeleteFileRequest()
|
10138
10502
|
model.from_json_string(json.dumps(args))
|
10139
10503
|
start_time = time.time()
|
10140
10504
|
while True:
|
10141
|
-
rsp = client.
|
10505
|
+
rsp = client.DeleteFile(model)
|
10142
10506
|
result = rsp.to_json_string()
|
10143
10507
|
try:
|
10144
10508
|
json_obj = json.loads(result)
|
@@ -11873,58 +12237,6 @@ def doDeleteCustomFunction(args, parsed_globals):
|
|
11873
12237
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
11874
12238
|
|
11875
12239
|
|
11876
|
-
def doDeleteFile(args, parsed_globals):
|
11877
|
-
g_param = parse_global_arg(parsed_globals)
|
11878
|
-
|
11879
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
11880
|
-
cred = credential.CVMRoleCredential()
|
11881
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
11882
|
-
cred = credential.STSAssumeRoleCredential(
|
11883
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
11884
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
11885
|
-
)
|
11886
|
-
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
11887
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
11888
|
-
else:
|
11889
|
-
cred = credential.Credential(
|
11890
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
11891
|
-
)
|
11892
|
-
http_profile = HttpProfile(
|
11893
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
11894
|
-
reqMethod="POST",
|
11895
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
11896
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
11897
|
-
)
|
11898
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
11899
|
-
if g_param[OptionsDefine.Language]:
|
11900
|
-
profile.language = g_param[OptionsDefine.Language]
|
11901
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
11902
|
-
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
11903
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
11904
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
11905
|
-
model = models.DeleteFileRequest()
|
11906
|
-
model.from_json_string(json.dumps(args))
|
11907
|
-
start_time = time.time()
|
11908
|
-
while True:
|
11909
|
-
rsp = client.DeleteFile(model)
|
11910
|
-
result = rsp.to_json_string()
|
11911
|
-
try:
|
11912
|
-
json_obj = json.loads(result)
|
11913
|
-
except TypeError as e:
|
11914
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
11915
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
11916
|
-
break
|
11917
|
-
cur_time = time.time()
|
11918
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
11919
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
11920
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
11921
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
11922
|
-
else:
|
11923
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
11924
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
11925
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
11926
|
-
|
11927
|
-
|
11928
12240
|
def doDescribeFolderWorkflowList(args, parsed_globals):
|
11929
12241
|
g_param = parse_global_arg(parsed_globals)
|
11930
12242
|
|
@@ -13797,6 +14109,58 @@ def doUpdateCodeTemplate(args, parsed_globals):
|
|
13797
14109
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
13798
14110
|
|
13799
14111
|
|
14112
|
+
def doGetOfflineDIInstanceList(args, parsed_globals):
|
14113
|
+
g_param = parse_global_arg(parsed_globals)
|
14114
|
+
|
14115
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
14116
|
+
cred = credential.CVMRoleCredential()
|
14117
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
14118
|
+
cred = credential.STSAssumeRoleCredential(
|
14119
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
14120
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
14121
|
+
)
|
14122
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
14123
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
14124
|
+
else:
|
14125
|
+
cred = credential.Credential(
|
14126
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
14127
|
+
)
|
14128
|
+
http_profile = HttpProfile(
|
14129
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
14130
|
+
reqMethod="POST",
|
14131
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
14132
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
14133
|
+
)
|
14134
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
14135
|
+
if g_param[OptionsDefine.Language]:
|
14136
|
+
profile.language = g_param[OptionsDefine.Language]
|
14137
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
14138
|
+
client = mod.WedataClient(cred, g_param[OptionsDefine.Region], profile)
|
14139
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
14140
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
14141
|
+
model = models.GetOfflineDIInstanceListRequest()
|
14142
|
+
model.from_json_string(json.dumps(args))
|
14143
|
+
start_time = time.time()
|
14144
|
+
while True:
|
14145
|
+
rsp = client.GetOfflineDIInstanceList(model)
|
14146
|
+
result = rsp.to_json_string()
|
14147
|
+
try:
|
14148
|
+
json_obj = json.loads(result)
|
14149
|
+
except TypeError as e:
|
14150
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
14151
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
14152
|
+
break
|
14153
|
+
cur_time = time.time()
|
14154
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
14155
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
14156
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
14157
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
14158
|
+
else:
|
14159
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
14160
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
14161
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
14162
|
+
|
14163
|
+
|
13800
14164
|
def doSuspendIntegrationTask(args, parsed_globals):
|
13801
14165
|
g_param = parse_global_arg(parsed_globals)
|
13802
14166
|
|
@@ -14726,10 +15090,12 @@ ACTION_MAP = {
|
|
14726
15090
|
"DescribeThirdTaskRunLog": doDescribeThirdTaskRunLog,
|
14727
15091
|
"DescribeDsParentFolderTree": doDescribeDsParentFolderTree,
|
14728
15092
|
"ResumeIntegrationTask": doResumeIntegrationTask,
|
15093
|
+
"CreateRule": doCreateRule,
|
14729
15094
|
"DescribeInstanceLogList": doDescribeInstanceLogList,
|
14730
15095
|
"CreateTaskVersionDs": doCreateTaskVersionDs,
|
14731
15096
|
"BatchModifyOpsOwners": doBatchModifyOpsOwners,
|
14732
15097
|
"CreateCustomFunction": doCreateCustomFunction,
|
15098
|
+
"BatchCreateTaskVersionAsync": doBatchCreateTaskVersionAsync,
|
14733
15099
|
"DescribeExecStrategy": doDescribeExecStrategy,
|
14734
15100
|
"UnlockIntegrationTask": doUnlockIntegrationTask,
|
14735
15101
|
"BatchStopIntegrationTasks": doBatchStopIntegrationTasks,
|
@@ -14755,7 +15121,7 @@ ACTION_MAP = {
|
|
14755
15121
|
"DescribeQualityScore": doDescribeQualityScore,
|
14756
15122
|
"DescribeExecutorGroupMetric": doDescribeExecutorGroupMetric,
|
14757
15123
|
"GetCosToken": doGetCosToken,
|
14758
|
-
"
|
15124
|
+
"EnableProject": doEnableProject,
|
14759
15125
|
"GenHiveTableDDLSql": doGenHiveTableDDLSql,
|
14760
15126
|
"DescribeTaskRunHistory": doDescribeTaskRunHistory,
|
14761
15127
|
"RunForceSucScheduleInstances": doRunForceSucScheduleInstances,
|
@@ -14788,6 +15154,7 @@ ACTION_MAP = {
|
|
14788
15154
|
"DescribeDutyScheduleDetails": doDescribeDutyScheduleDetails,
|
14789
15155
|
"DescribeIntegrationStatisticsTaskStatus": doDescribeIntegrationStatisticsTaskStatus,
|
14790
15156
|
"BatchStartIntegrationTasks": doBatchStartIntegrationTasks,
|
15157
|
+
"DisableProject": doDisableProject,
|
14791
15158
|
"ModifyTaskName": doModifyTaskName,
|
14792
15159
|
"DescribeRuleExecDetail": doDescribeRuleExecDetail,
|
14793
15160
|
"CheckTaskNameExist": doCheckTaskNameExist,
|
@@ -14799,6 +15166,7 @@ ACTION_MAP = {
|
|
14799
15166
|
"BatchRerunIntegrationTaskInstances": doBatchRerunIntegrationTaskInstances,
|
14800
15167
|
"DescribeTaskTemplates": doDescribeTaskTemplates,
|
14801
15168
|
"DescribeSchedulerTaskCntByStatus": doDescribeSchedulerTaskCntByStatus,
|
15169
|
+
"BindProjectExecutorResource": doBindProjectExecutorResource,
|
14802
15170
|
"ModifyWorkflowSchedule": doModifyWorkflowSchedule,
|
14803
15171
|
"DescribeTableSchemaInfo": doDescribeTableSchemaInfo,
|
14804
15172
|
"ModifyRule": doModifyRule,
|
@@ -14849,6 +15217,7 @@ ACTION_MAP = {
|
|
14849
15217
|
"CreateWorkflowDs": doCreateWorkflowDs,
|
14850
15218
|
"DescribeEvent": doDescribeEvent,
|
14851
15219
|
"DescribeTableScoreTrend": doDescribeTableScoreTrend,
|
15220
|
+
"CreateBaseProject": doCreateBaseProject,
|
14852
15221
|
"DescribeTableQualityDetails": doDescribeTableQualityDetails,
|
14853
15222
|
"DescribeRuleGroupsByPage": doDescribeRuleGroupsByPage,
|
14854
15223
|
"DeleteDataSources": doDeleteDataSources,
|
@@ -14861,9 +15230,9 @@ ACTION_MAP = {
|
|
14861
15230
|
"CheckIntegrationTaskNameExists": doCheckIntegrationTaskNameExists,
|
14862
15231
|
"DescribeTablePartitions": doDescribeTablePartitions,
|
14863
15232
|
"UploadResource": doUploadResource,
|
14864
|
-
"
|
15233
|
+
"ModifyProject": doModifyProject,
|
14865
15234
|
"DeleteProjectUsers": doDeleteProjectUsers,
|
14866
|
-
"
|
15235
|
+
"DescribeRelatedTasksByTaskId": doDescribeRelatedTasksByTaskId,
|
14867
15236
|
"BatchMakeUpIntegrationTasks": doBatchMakeUpIntegrationTasks,
|
14868
15237
|
"DescribeRulesByPage": doDescribeRulesByPage,
|
14869
15238
|
"DescribeDsTaskVersionList": doDescribeDsTaskVersionList,
|
@@ -14881,12 +15250,14 @@ ACTION_MAP = {
|
|
14881
15250
|
"DescribeInstanceLogFile": doDescribeInstanceLogFile,
|
14882
15251
|
"DescribeIntegrationStatisticsTaskStatusTrend": doDescribeIntegrationStatisticsTaskStatusTrend,
|
14883
15252
|
"ModifyMonitorStatus": doModifyMonitorStatus,
|
15253
|
+
"DeleteTaskLineage": doDeleteTaskLineage,
|
14884
15254
|
"DescribeAllByFolderNew": doDescribeAllByFolderNew,
|
14885
15255
|
"UpdateWorkflowOwner": doUpdateWorkflowOwner,
|
14886
15256
|
"UpdateWorkflowInfo": doUpdateWorkflowInfo,
|
15257
|
+
"UnboundProjectExecutorResource": doUnboundProjectExecutorResource,
|
14887
15258
|
"DescribeTableLineage": doDescribeTableLineage,
|
14888
15259
|
"DescribeEventCases": doDescribeEventCases,
|
14889
|
-
"
|
15260
|
+
"DeleteFile": doDeleteFile,
|
14890
15261
|
"DeleteWorkflowById": doDeleteWorkflowById,
|
14891
15262
|
"DescribeRules": doDescribeRules,
|
14892
15263
|
"RobAndLockIntegrationTask": doRobAndLockIntegrationTask,
|
@@ -14920,7 +15291,6 @@ ACTION_MAP = {
|
|
14920
15291
|
"DescribeProjectUsers": doDescribeProjectUsers,
|
14921
15292
|
"DescribeWorkflowSchedulerInfoDs": doDescribeWorkflowSchedulerInfoDs,
|
14922
15293
|
"DeleteCustomFunction": doDeleteCustomFunction,
|
14923
|
-
"DeleteFile": doDeleteFile,
|
14924
15294
|
"DescribeFolderWorkflowList": doDescribeFolderWorkflowList,
|
14925
15295
|
"DescribeIntegrationTask": doDescribeIntegrationTask,
|
14926
15296
|
"DescribeDataServicePublishedApiDetail": doDescribeDataServicePublishedApiDetail,
|
@@ -14957,6 +15327,7 @@ ACTION_MAP = {
|
|
14957
15327
|
"TaskLog": doTaskLog,
|
14958
15328
|
"DescribeRuleTemplates": doDescribeRuleTemplates,
|
14959
15329
|
"UpdateCodeTemplate": doUpdateCodeTemplate,
|
15330
|
+
"GetOfflineDIInstanceList": doGetOfflineDIInstanceList,
|
14960
15331
|
"SuspendIntegrationTask": doSuspendIntegrationTask,
|
14961
15332
|
"LockIntegrationTask": doLockIntegrationTask,
|
14962
15333
|
"RegisterDsEventListener": doRegisterDsEventListener,
|