huaweicloudsdkmrs 3.1.71__py2.py3-none-any.whl → 3.1.73__py2.py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- huaweicloudsdkmrs/v1/__init__.py +9 -0
- huaweicloudsdkmrs/v1/model/__init__.py +9 -0
- huaweicloudsdkmrs/v1/model/component_external_datasource.py +144 -0
- huaweicloudsdkmrs/v1/model/flavor_lists.py +173 -0
- huaweicloudsdkmrs/v1/model/node_constraint.py +376 -0
- huaweicloudsdkmrs/v1/model/node_constraints.py +315 -0
- huaweicloudsdkmrs/v1/model/role_deploy_meta.py +637 -0
- huaweicloudsdkmrs/v1/model/show_mrs_version_metadata_request.py +143 -0
- huaweicloudsdkmrs/v1/model/show_mrs_version_metadata_response.py +456 -0
- huaweicloudsdkmrs/v1/model/version_component.py +434 -0
- huaweicloudsdkmrs/v1/model/version_constraint.py +169 -0
- huaweicloudsdkmrs/v1/mrs_async_client.py +67 -0
- huaweicloudsdkmrs/v1/mrs_client.py +67 -0
- huaweicloudsdkmrs/v1/region/mrs_region.py +6 -0
- huaweicloudsdkmrs/v2/__init__.py +7 -0
- huaweicloudsdkmrs/v2/model/__init__.py +7 -0
- huaweicloudsdkmrs/v2/model/modify_default_tags_request_body.py +114 -0
- huaweicloudsdkmrs/v2/model/show_tag_quota_request.py +143 -0
- huaweicloudsdkmrs/v2/model/show_tag_quota_response.py +145 -0
- huaweicloudsdkmrs/v2/model/show_tag_status_request.py +114 -0
- huaweicloudsdkmrs/v2/model/show_tag_status_response.py +145 -0
- huaweicloudsdkmrs/v2/model/switch_cluster_tags_request.py +139 -0
- huaweicloudsdkmrs/v2/model/switch_cluster_tags_response.py +85 -0
- huaweicloudsdkmrs/v2/mrs_async_client.py +199 -0
- huaweicloudsdkmrs/v2/mrs_client.py +199 -0
- huaweicloudsdkmrs/v2/region/mrs_region.py +6 -0
- {huaweicloudsdkmrs-3.1.71.dist-info → huaweicloudsdkmrs-3.1.73.dist-info}/METADATA +2 -2
- {huaweicloudsdkmrs-3.1.71.dist-info → huaweicloudsdkmrs-3.1.73.dist-info}/RECORD +31 -15
- {huaweicloudsdkmrs-3.1.71.dist-info → huaweicloudsdkmrs-3.1.73.dist-info}/LICENSE +0 -0
- {huaweicloudsdkmrs-3.1.71.dist-info → huaweicloudsdkmrs-3.1.73.dist-info}/WHEEL +0 -0
- {huaweicloudsdkmrs-3.1.71.dist-info → huaweicloudsdkmrs-3.1.73.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,145 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.sdk_response import SdkResponse
|
6
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
7
|
+
|
8
|
+
|
9
|
+
class ShowTagStatusResponse(SdkResponse):
|
10
|
+
|
11
|
+
"""
|
12
|
+
Attributes:
|
13
|
+
openapi_types (dict): The key is attribute name
|
14
|
+
and the value is attribute type.
|
15
|
+
attribute_map (dict): The key is attribute name
|
16
|
+
and the value is json key in definition.
|
17
|
+
"""
|
18
|
+
sensitive_list = []
|
19
|
+
|
20
|
+
openapi_types = {
|
21
|
+
'status': 'str',
|
22
|
+
'default_tags_enable': 'bool'
|
23
|
+
}
|
24
|
+
|
25
|
+
attribute_map = {
|
26
|
+
'status': 'status',
|
27
|
+
'default_tags_enable': 'default_tags_enable'
|
28
|
+
}
|
29
|
+
|
30
|
+
def __init__(self, status=None, default_tags_enable=None):
|
31
|
+
"""ShowTagStatusResponse
|
32
|
+
|
33
|
+
The model defined in huaweicloud sdk
|
34
|
+
|
35
|
+
:param status: 标签处理状态
|
36
|
+
:type status: str
|
37
|
+
:param default_tags_enable: 默认标签是否已开启
|
38
|
+
:type default_tags_enable: bool
|
39
|
+
"""
|
40
|
+
|
41
|
+
super(ShowTagStatusResponse, self).__init__()
|
42
|
+
|
43
|
+
self._status = None
|
44
|
+
self._default_tags_enable = None
|
45
|
+
self.discriminator = None
|
46
|
+
|
47
|
+
if status is not None:
|
48
|
+
self.status = status
|
49
|
+
if default_tags_enable is not None:
|
50
|
+
self.default_tags_enable = default_tags_enable
|
51
|
+
|
52
|
+
@property
|
53
|
+
def status(self):
|
54
|
+
"""Gets the status of this ShowTagStatusResponse.
|
55
|
+
|
56
|
+
标签处理状态
|
57
|
+
|
58
|
+
:return: The status of this ShowTagStatusResponse.
|
59
|
+
:rtype: str
|
60
|
+
"""
|
61
|
+
return self._status
|
62
|
+
|
63
|
+
@status.setter
|
64
|
+
def status(self, status):
|
65
|
+
"""Sets the status of this ShowTagStatusResponse.
|
66
|
+
|
67
|
+
标签处理状态
|
68
|
+
|
69
|
+
:param status: The status of this ShowTagStatusResponse.
|
70
|
+
:type status: str
|
71
|
+
"""
|
72
|
+
self._status = status
|
73
|
+
|
74
|
+
@property
|
75
|
+
def default_tags_enable(self):
|
76
|
+
"""Gets the default_tags_enable of this ShowTagStatusResponse.
|
77
|
+
|
78
|
+
默认标签是否已开启
|
79
|
+
|
80
|
+
:return: The default_tags_enable of this ShowTagStatusResponse.
|
81
|
+
:rtype: bool
|
82
|
+
"""
|
83
|
+
return self._default_tags_enable
|
84
|
+
|
85
|
+
@default_tags_enable.setter
|
86
|
+
def default_tags_enable(self, default_tags_enable):
|
87
|
+
"""Sets the default_tags_enable of this ShowTagStatusResponse.
|
88
|
+
|
89
|
+
默认标签是否已开启
|
90
|
+
|
91
|
+
:param default_tags_enable: The default_tags_enable of this ShowTagStatusResponse.
|
92
|
+
:type default_tags_enable: bool
|
93
|
+
"""
|
94
|
+
self._default_tags_enable = default_tags_enable
|
95
|
+
|
96
|
+
def to_dict(self):
|
97
|
+
"""Returns the model properties as a dict"""
|
98
|
+
result = {}
|
99
|
+
|
100
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
101
|
+
value = getattr(self, attr)
|
102
|
+
if isinstance(value, list):
|
103
|
+
result[attr] = list(map(
|
104
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
105
|
+
value
|
106
|
+
))
|
107
|
+
elif hasattr(value, "to_dict"):
|
108
|
+
result[attr] = value.to_dict()
|
109
|
+
elif isinstance(value, dict):
|
110
|
+
result[attr] = dict(map(
|
111
|
+
lambda item: (item[0], item[1].to_dict())
|
112
|
+
if hasattr(item[1], "to_dict") else item,
|
113
|
+
value.items()
|
114
|
+
))
|
115
|
+
else:
|
116
|
+
if attr in self.sensitive_list:
|
117
|
+
result[attr] = "****"
|
118
|
+
else:
|
119
|
+
result[attr] = value
|
120
|
+
|
121
|
+
return result
|
122
|
+
|
123
|
+
def to_str(self):
|
124
|
+
"""Returns the string representation of the model"""
|
125
|
+
import simplejson as json
|
126
|
+
if six.PY2:
|
127
|
+
import sys
|
128
|
+
reload(sys)
|
129
|
+
sys.setdefaultencoding("utf-8")
|
130
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
131
|
+
|
132
|
+
def __repr__(self):
|
133
|
+
"""For `print`"""
|
134
|
+
return self.to_str()
|
135
|
+
|
136
|
+
def __eq__(self, other):
|
137
|
+
"""Returns true if both objects are equal"""
|
138
|
+
if not isinstance(other, ShowTagStatusResponse):
|
139
|
+
return False
|
140
|
+
|
141
|
+
return self.__dict__ == other.__dict__
|
142
|
+
|
143
|
+
def __ne__(self, other):
|
144
|
+
"""Returns true if both objects are not equal"""
|
145
|
+
return not self == other
|
@@ -0,0 +1,139 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
6
|
+
|
7
|
+
|
8
|
+
class SwitchClusterTagsRequest:
|
9
|
+
|
10
|
+
"""
|
11
|
+
Attributes:
|
12
|
+
openapi_types (dict): The key is attribute name
|
13
|
+
and the value is attribute type.
|
14
|
+
attribute_map (dict): The key is attribute name
|
15
|
+
and the value is json key in definition.
|
16
|
+
"""
|
17
|
+
sensitive_list = []
|
18
|
+
|
19
|
+
openapi_types = {
|
20
|
+
'cluster_id': 'str',
|
21
|
+
'body': 'ModifyDefaultTagsRequestBody'
|
22
|
+
}
|
23
|
+
|
24
|
+
attribute_map = {
|
25
|
+
'cluster_id': 'cluster_id',
|
26
|
+
'body': 'body'
|
27
|
+
}
|
28
|
+
|
29
|
+
def __init__(self, cluster_id=None, body=None):
|
30
|
+
"""SwitchClusterTagsRequest
|
31
|
+
|
32
|
+
The model defined in huaweicloud sdk
|
33
|
+
|
34
|
+
:param cluster_id: 集群ID。
|
35
|
+
:type cluster_id: str
|
36
|
+
:param body: Body of the SwitchClusterTagsRequest
|
37
|
+
:type body: :class:`huaweicloudsdkmrs.v2.ModifyDefaultTagsRequestBody`
|
38
|
+
"""
|
39
|
+
|
40
|
+
|
41
|
+
|
42
|
+
self._cluster_id = None
|
43
|
+
self._body = None
|
44
|
+
self.discriminator = None
|
45
|
+
|
46
|
+
self.cluster_id = cluster_id
|
47
|
+
if body is not None:
|
48
|
+
self.body = body
|
49
|
+
|
50
|
+
@property
|
51
|
+
def cluster_id(self):
|
52
|
+
"""Gets the cluster_id of this SwitchClusterTagsRequest.
|
53
|
+
|
54
|
+
集群ID。
|
55
|
+
|
56
|
+
:return: The cluster_id of this SwitchClusterTagsRequest.
|
57
|
+
:rtype: str
|
58
|
+
"""
|
59
|
+
return self._cluster_id
|
60
|
+
|
61
|
+
@cluster_id.setter
|
62
|
+
def cluster_id(self, cluster_id):
|
63
|
+
"""Sets the cluster_id of this SwitchClusterTagsRequest.
|
64
|
+
|
65
|
+
集群ID。
|
66
|
+
|
67
|
+
:param cluster_id: The cluster_id of this SwitchClusterTagsRequest.
|
68
|
+
:type cluster_id: str
|
69
|
+
"""
|
70
|
+
self._cluster_id = cluster_id
|
71
|
+
|
72
|
+
@property
|
73
|
+
def body(self):
|
74
|
+
"""Gets the body of this SwitchClusterTagsRequest.
|
75
|
+
|
76
|
+
:return: The body of this SwitchClusterTagsRequest.
|
77
|
+
:rtype: :class:`huaweicloudsdkmrs.v2.ModifyDefaultTagsRequestBody`
|
78
|
+
"""
|
79
|
+
return self._body
|
80
|
+
|
81
|
+
@body.setter
|
82
|
+
def body(self, body):
|
83
|
+
"""Sets the body of this SwitchClusterTagsRequest.
|
84
|
+
|
85
|
+
:param body: The body of this SwitchClusterTagsRequest.
|
86
|
+
:type body: :class:`huaweicloudsdkmrs.v2.ModifyDefaultTagsRequestBody`
|
87
|
+
"""
|
88
|
+
self._body = body
|
89
|
+
|
90
|
+
def to_dict(self):
|
91
|
+
"""Returns the model properties as a dict"""
|
92
|
+
result = {}
|
93
|
+
|
94
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
95
|
+
value = getattr(self, attr)
|
96
|
+
if isinstance(value, list):
|
97
|
+
result[attr] = list(map(
|
98
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
99
|
+
value
|
100
|
+
))
|
101
|
+
elif hasattr(value, "to_dict"):
|
102
|
+
result[attr] = value.to_dict()
|
103
|
+
elif isinstance(value, dict):
|
104
|
+
result[attr] = dict(map(
|
105
|
+
lambda item: (item[0], item[1].to_dict())
|
106
|
+
if hasattr(item[1], "to_dict") else item,
|
107
|
+
value.items()
|
108
|
+
))
|
109
|
+
else:
|
110
|
+
if attr in self.sensitive_list:
|
111
|
+
result[attr] = "****"
|
112
|
+
else:
|
113
|
+
result[attr] = value
|
114
|
+
|
115
|
+
return result
|
116
|
+
|
117
|
+
def to_str(self):
|
118
|
+
"""Returns the string representation of the model"""
|
119
|
+
import simplejson as json
|
120
|
+
if six.PY2:
|
121
|
+
import sys
|
122
|
+
reload(sys)
|
123
|
+
sys.setdefaultencoding("utf-8")
|
124
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
125
|
+
|
126
|
+
def __repr__(self):
|
127
|
+
"""For `print`"""
|
128
|
+
return self.to_str()
|
129
|
+
|
130
|
+
def __eq__(self, other):
|
131
|
+
"""Returns true if both objects are equal"""
|
132
|
+
if not isinstance(other, SwitchClusterTagsRequest):
|
133
|
+
return False
|
134
|
+
|
135
|
+
return self.__dict__ == other.__dict__
|
136
|
+
|
137
|
+
def __ne__(self, other):
|
138
|
+
"""Returns true if both objects are not equal"""
|
139
|
+
return not self == other
|
@@ -0,0 +1,85 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.sdk_response import SdkResponse
|
6
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
7
|
+
|
8
|
+
|
9
|
+
class SwitchClusterTagsResponse(SdkResponse):
|
10
|
+
|
11
|
+
"""
|
12
|
+
Attributes:
|
13
|
+
openapi_types (dict): The key is attribute name
|
14
|
+
and the value is attribute type.
|
15
|
+
attribute_map (dict): The key is attribute name
|
16
|
+
and the value is json key in definition.
|
17
|
+
"""
|
18
|
+
sensitive_list = []
|
19
|
+
|
20
|
+
openapi_types = {
|
21
|
+
}
|
22
|
+
|
23
|
+
attribute_map = {
|
24
|
+
}
|
25
|
+
|
26
|
+
def __init__(self):
|
27
|
+
"""SwitchClusterTagsResponse
|
28
|
+
|
29
|
+
The model defined in huaweicloud sdk
|
30
|
+
|
31
|
+
"""
|
32
|
+
|
33
|
+
super(SwitchClusterTagsResponse, self).__init__()
|
34
|
+
self.discriminator = None
|
35
|
+
|
36
|
+
def to_dict(self):
|
37
|
+
"""Returns the model properties as a dict"""
|
38
|
+
result = {}
|
39
|
+
|
40
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
41
|
+
value = getattr(self, attr)
|
42
|
+
if isinstance(value, list):
|
43
|
+
result[attr] = list(map(
|
44
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
45
|
+
value
|
46
|
+
))
|
47
|
+
elif hasattr(value, "to_dict"):
|
48
|
+
result[attr] = value.to_dict()
|
49
|
+
elif isinstance(value, dict):
|
50
|
+
result[attr] = dict(map(
|
51
|
+
lambda item: (item[0], item[1].to_dict())
|
52
|
+
if hasattr(item[1], "to_dict") else item,
|
53
|
+
value.items()
|
54
|
+
))
|
55
|
+
else:
|
56
|
+
if attr in self.sensitive_list:
|
57
|
+
result[attr] = "****"
|
58
|
+
else:
|
59
|
+
result[attr] = value
|
60
|
+
|
61
|
+
return result
|
62
|
+
|
63
|
+
def to_str(self):
|
64
|
+
"""Returns the string representation of the model"""
|
65
|
+
import simplejson as json
|
66
|
+
if six.PY2:
|
67
|
+
import sys
|
68
|
+
reload(sys)
|
69
|
+
sys.setdefaultencoding("utf-8")
|
70
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
71
|
+
|
72
|
+
def __repr__(self):
|
73
|
+
"""For `print`"""
|
74
|
+
return self.to_str()
|
75
|
+
|
76
|
+
def __eq__(self, other):
|
77
|
+
"""Returns true if both objects are equal"""
|
78
|
+
if not isinstance(other, SwitchClusterTagsResponse):
|
79
|
+
return False
|
80
|
+
|
81
|
+
return self.__dict__ == other.__dict__
|
82
|
+
|
83
|
+
def __ne__(self, other):
|
84
|
+
"""Returns true if both objects are not equal"""
|
85
|
+
return not self == other
|
@@ -1814,6 +1814,205 @@ class MrsAsyncClient(Client):
|
|
1814
1814
|
|
1815
1815
|
return http_info
|
1816
1816
|
|
1817
|
+
def show_tag_quota_async(self, request):
|
1818
|
+
"""查询标签配额
|
1819
|
+
|
1820
|
+
查询标签配额信息
|
1821
|
+
|
1822
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
1823
|
+
|
1824
|
+
|
1825
|
+
:param request: Request instance for ShowTagQuota
|
1826
|
+
:type request: :class:`huaweicloudsdkmrs.v2.ShowTagQuotaRequest`
|
1827
|
+
:rtype: :class:`huaweicloudsdkmrs.v2.ShowTagQuotaResponse`
|
1828
|
+
"""
|
1829
|
+
http_info = self._show_tag_quota_http_info(request)
|
1830
|
+
return self._call_api(**http_info)
|
1831
|
+
|
1832
|
+
def show_tag_quota_async_invoker(self, request):
|
1833
|
+
http_info = self._show_tag_quota_http_info(request)
|
1834
|
+
return AsyncInvoker(self, http_info)
|
1835
|
+
|
1836
|
+
def _show_tag_quota_http_info(self, request):
|
1837
|
+
http_info = {
|
1838
|
+
"method": "GET",
|
1839
|
+
"resource_path": "/v2/{project_id}/clusters/{cluster_id}/tags/quota",
|
1840
|
+
"request_type": request.__class__.__name__,
|
1841
|
+
"response_type": "ShowTagQuotaResponse"
|
1842
|
+
}
|
1843
|
+
|
1844
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
1845
|
+
|
1846
|
+
cname = None
|
1847
|
+
|
1848
|
+
collection_formats = {}
|
1849
|
+
|
1850
|
+
path_params = {}
|
1851
|
+
if 'cluster_id' in local_var_params:
|
1852
|
+
path_params['cluster_id'] = local_var_params['cluster_id']
|
1853
|
+
|
1854
|
+
query_params = []
|
1855
|
+
if 'auto_scaling_policy_tags' in local_var_params:
|
1856
|
+
query_params.append(('auto_scaling_policy_tags', local_var_params['auto_scaling_policy_tags']))
|
1857
|
+
|
1858
|
+
header_params = {}
|
1859
|
+
|
1860
|
+
form_params = {}
|
1861
|
+
|
1862
|
+
body = None
|
1863
|
+
if isinstance(request, SdkStreamRequest):
|
1864
|
+
body = request.get_file_stream()
|
1865
|
+
|
1866
|
+
response_headers = []
|
1867
|
+
|
1868
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
1869
|
+
['application/json'])
|
1870
|
+
|
1871
|
+
auth_settings = []
|
1872
|
+
|
1873
|
+
http_info["cname"] = cname
|
1874
|
+
http_info["collection_formats"] = collection_formats
|
1875
|
+
http_info["path_params"] = path_params
|
1876
|
+
http_info["query_params"] = query_params
|
1877
|
+
http_info["header_params"] = header_params
|
1878
|
+
http_info["post_params"] = form_params
|
1879
|
+
http_info["body"] = body
|
1880
|
+
http_info["response_headers"] = response_headers
|
1881
|
+
|
1882
|
+
return http_info
|
1883
|
+
|
1884
|
+
def show_tag_status_async(self, request):
|
1885
|
+
"""查询默认标签状态
|
1886
|
+
|
1887
|
+
查询集群默认标签状态
|
1888
|
+
|
1889
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
1890
|
+
|
1891
|
+
|
1892
|
+
:param request: Request instance for ShowTagStatus
|
1893
|
+
:type request: :class:`huaweicloudsdkmrs.v2.ShowTagStatusRequest`
|
1894
|
+
:rtype: :class:`huaweicloudsdkmrs.v2.ShowTagStatusResponse`
|
1895
|
+
"""
|
1896
|
+
http_info = self._show_tag_status_http_info(request)
|
1897
|
+
return self._call_api(**http_info)
|
1898
|
+
|
1899
|
+
def show_tag_status_async_invoker(self, request):
|
1900
|
+
http_info = self._show_tag_status_http_info(request)
|
1901
|
+
return AsyncInvoker(self, http_info)
|
1902
|
+
|
1903
|
+
def _show_tag_status_http_info(self, request):
|
1904
|
+
http_info = {
|
1905
|
+
"method": "GET",
|
1906
|
+
"resource_path": "/v2/{project_id}/clusters/{cluster_id}/tags/status",
|
1907
|
+
"request_type": request.__class__.__name__,
|
1908
|
+
"response_type": "ShowTagStatusResponse"
|
1909
|
+
}
|
1910
|
+
|
1911
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
1912
|
+
|
1913
|
+
cname = None
|
1914
|
+
|
1915
|
+
collection_formats = {}
|
1916
|
+
|
1917
|
+
path_params = {}
|
1918
|
+
if 'cluster_id' in local_var_params:
|
1919
|
+
path_params['cluster_id'] = local_var_params['cluster_id']
|
1920
|
+
|
1921
|
+
query_params = []
|
1922
|
+
|
1923
|
+
header_params = {}
|
1924
|
+
|
1925
|
+
form_params = {}
|
1926
|
+
|
1927
|
+
body = None
|
1928
|
+
if isinstance(request, SdkStreamRequest):
|
1929
|
+
body = request.get_file_stream()
|
1930
|
+
|
1931
|
+
response_headers = []
|
1932
|
+
|
1933
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
1934
|
+
['application/json'])
|
1935
|
+
|
1936
|
+
auth_settings = []
|
1937
|
+
|
1938
|
+
http_info["cname"] = cname
|
1939
|
+
http_info["collection_formats"] = collection_formats
|
1940
|
+
http_info["path_params"] = path_params
|
1941
|
+
http_info["query_params"] = query_params
|
1942
|
+
http_info["header_params"] = header_params
|
1943
|
+
http_info["post_params"] = form_params
|
1944
|
+
http_info["body"] = body
|
1945
|
+
http_info["response_headers"] = response_headers
|
1946
|
+
|
1947
|
+
return http_info
|
1948
|
+
|
1949
|
+
def switch_cluster_tags_async(self, request):
|
1950
|
+
"""集群操作默认标签
|
1951
|
+
|
1952
|
+
对已有集群启用或关闭集群默认标签。开启后,集群内节点会打上集群默认标签。
|
1953
|
+
|
1954
|
+
Please refer to HUAWEI cloud API Explorer for details.
|
1955
|
+
|
1956
|
+
|
1957
|
+
:param request: Request instance for SwitchClusterTags
|
1958
|
+
:type request: :class:`huaweicloudsdkmrs.v2.SwitchClusterTagsRequest`
|
1959
|
+
:rtype: :class:`huaweicloudsdkmrs.v2.SwitchClusterTagsResponse`
|
1960
|
+
"""
|
1961
|
+
http_info = self._switch_cluster_tags_http_info(request)
|
1962
|
+
return self._call_api(**http_info)
|
1963
|
+
|
1964
|
+
def switch_cluster_tags_async_invoker(self, request):
|
1965
|
+
http_info = self._switch_cluster_tags_http_info(request)
|
1966
|
+
return AsyncInvoker(self, http_info)
|
1967
|
+
|
1968
|
+
def _switch_cluster_tags_http_info(self, request):
|
1969
|
+
http_info = {
|
1970
|
+
"method": "POST",
|
1971
|
+
"resource_path": "/v2/{project_id}/clusters/{cluster_id}/tags/switch",
|
1972
|
+
"request_type": request.__class__.__name__,
|
1973
|
+
"response_type": "SwitchClusterTagsResponse"
|
1974
|
+
}
|
1975
|
+
|
1976
|
+
local_var_params = {attr: getattr(request, attr) for attr in request.attribute_map if hasattr(request, attr)}
|
1977
|
+
|
1978
|
+
cname = None
|
1979
|
+
|
1980
|
+
collection_formats = {}
|
1981
|
+
|
1982
|
+
path_params = {}
|
1983
|
+
if 'cluster_id' in local_var_params:
|
1984
|
+
path_params['cluster_id'] = local_var_params['cluster_id']
|
1985
|
+
|
1986
|
+
query_params = []
|
1987
|
+
|
1988
|
+
header_params = {}
|
1989
|
+
|
1990
|
+
form_params = {}
|
1991
|
+
|
1992
|
+
body = None
|
1993
|
+
if 'body' in local_var_params:
|
1994
|
+
body = local_var_params['body']
|
1995
|
+
if isinstance(request, SdkStreamRequest):
|
1996
|
+
body = request.get_file_stream()
|
1997
|
+
|
1998
|
+
response_headers = []
|
1999
|
+
|
2000
|
+
header_params['Content-Type'] = http_utils.select_header_content_type(
|
2001
|
+
['application/json;charset=UTF-8'])
|
2002
|
+
|
2003
|
+
auth_settings = []
|
2004
|
+
|
2005
|
+
http_info["cname"] = cname
|
2006
|
+
http_info["collection_formats"] = collection_formats
|
2007
|
+
http_info["path_params"] = path_params
|
2008
|
+
http_info["query_params"] = query_params
|
2009
|
+
http_info["header_params"] = header_params
|
2010
|
+
http_info["post_params"] = form_params
|
2011
|
+
http_info["body"] = body
|
2012
|
+
http_info["response_headers"] = response_headers
|
2013
|
+
|
2014
|
+
return http_info
|
2015
|
+
|
1817
2016
|
def show_mrs_version_list_async(self, request):
|
1818
2017
|
"""展示MRS版本列表
|
1819
2018
|
|