huaweicloudsdkgaussdbforopengauss 3.1.102__py2.py3-none-any.whl → 3.1.103__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.
- huaweicloudsdkgaussdbforopengauss/v3/__init__.py +19 -0
- huaweicloudsdkgaussdbforopengauss/v3/gaussdbforopengauss_async_client.py +367 -0
- huaweicloudsdkgaussdbforopengauss/v3/gaussdbforopengauss_client.py +367 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/__init__.py +19 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/backup_policy_info.py +314 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/confirm_restored_data_request.py +143 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/confirm_restored_data_response.py +116 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/gauss_db_upgrade_instances_version_request.py +201 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/hotfix_info.py +202 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/hotfix_version_info.py +143 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/list_instance_datastore.py +258 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/list_instance_details_request.py +405 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/list_instance_details_response.py +145 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/list_instances_result.py +957 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/my_sql_compatibility_result.py +115 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/open_gauss_instance_request.py +3 -3
- huaweicloudsdkgaussdbforopengauss/v3/model/open_gauss_instance_request_body.py +3 -3
- huaweicloudsdkgaussdbforopengauss/v3/model/set_new_backup_policy_request.py +168 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/set_new_backup_policy_request_body.py +110 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/set_new_backup_policy_response.py +85 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/show_batch_upgrade_candidate_versions_request.py +140 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/show_batch_upgrade_candidate_versions_response.py +203 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/upgrade_instances_request_body.py +115 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/upgrade_instances_version_request.py +140 -0
- huaweicloudsdkgaussdbforopengauss/v3/model/upgrade_instances_version_response.py +232 -0
- {huaweicloudsdkgaussdbforopengauss-3.1.102.dist-info → huaweicloudsdkgaussdbforopengauss-3.1.103.dist-info}/METADATA +2 -2
- {huaweicloudsdkgaussdbforopengauss-3.1.102.dist-info → huaweicloudsdkgaussdbforopengauss-3.1.103.dist-info}/RECORD +30 -11
- {huaweicloudsdkgaussdbforopengauss-3.1.102.dist-info → huaweicloudsdkgaussdbforopengauss-3.1.103.dist-info}/LICENSE +0 -0
- {huaweicloudsdkgaussdbforopengauss-3.1.102.dist-info → huaweicloudsdkgaussdbforopengauss-3.1.103.dist-info}/WHEEL +0 -0
- {huaweicloudsdkgaussdbforopengauss-3.1.102.dist-info → huaweicloudsdkgaussdbforopengauss-3.1.103.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,115 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
6
|
+
|
7
|
+
|
8
|
+
class MySQLCompatibilityResult:
|
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
|
+
'port': 'str'
|
21
|
+
}
|
22
|
+
|
23
|
+
attribute_map = {
|
24
|
+
'port': 'port'
|
25
|
+
}
|
26
|
+
|
27
|
+
def __init__(self, port=None):
|
28
|
+
"""MySQLCompatibilityResult
|
29
|
+
|
30
|
+
The model defined in huaweicloud sdk
|
31
|
+
|
32
|
+
:param port: MySQL兼容端口
|
33
|
+
:type port: str
|
34
|
+
"""
|
35
|
+
|
36
|
+
|
37
|
+
|
38
|
+
self._port = None
|
39
|
+
self.discriminator = None
|
40
|
+
|
41
|
+
if port is not None:
|
42
|
+
self.port = port
|
43
|
+
|
44
|
+
@property
|
45
|
+
def port(self):
|
46
|
+
"""Gets the port of this MySQLCompatibilityResult.
|
47
|
+
|
48
|
+
MySQL兼容端口
|
49
|
+
|
50
|
+
:return: The port of this MySQLCompatibilityResult.
|
51
|
+
:rtype: str
|
52
|
+
"""
|
53
|
+
return self._port
|
54
|
+
|
55
|
+
@port.setter
|
56
|
+
def port(self, port):
|
57
|
+
"""Sets the port of this MySQLCompatibilityResult.
|
58
|
+
|
59
|
+
MySQL兼容端口
|
60
|
+
|
61
|
+
:param port: The port of this MySQLCompatibilityResult.
|
62
|
+
:type port: str
|
63
|
+
"""
|
64
|
+
self._port = port
|
65
|
+
|
66
|
+
def to_dict(self):
|
67
|
+
"""Returns the model properties as a dict"""
|
68
|
+
result = {}
|
69
|
+
|
70
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
71
|
+
value = getattr(self, attr)
|
72
|
+
if isinstance(value, list):
|
73
|
+
result[attr] = list(map(
|
74
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
75
|
+
value
|
76
|
+
))
|
77
|
+
elif hasattr(value, "to_dict"):
|
78
|
+
result[attr] = value.to_dict()
|
79
|
+
elif isinstance(value, dict):
|
80
|
+
result[attr] = dict(map(
|
81
|
+
lambda item: (item[0], item[1].to_dict())
|
82
|
+
if hasattr(item[1], "to_dict") else item,
|
83
|
+
value.items()
|
84
|
+
))
|
85
|
+
else:
|
86
|
+
if attr in self.sensitive_list:
|
87
|
+
result[attr] = "****"
|
88
|
+
else:
|
89
|
+
result[attr] = value
|
90
|
+
|
91
|
+
return result
|
92
|
+
|
93
|
+
def to_str(self):
|
94
|
+
"""Returns the string representation of the model"""
|
95
|
+
import simplejson as json
|
96
|
+
if six.PY2:
|
97
|
+
import sys
|
98
|
+
reload(sys)
|
99
|
+
sys.setdefaultencoding("utf-8")
|
100
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
101
|
+
|
102
|
+
def __repr__(self):
|
103
|
+
"""For `print`"""
|
104
|
+
return self.to_str()
|
105
|
+
|
106
|
+
def __eq__(self, other):
|
107
|
+
"""Returns true if both objects are equal"""
|
108
|
+
if not isinstance(other, MySQLCompatibilityResult):
|
109
|
+
return False
|
110
|
+
|
111
|
+
return self.__dict__ == other.__dict__
|
112
|
+
|
113
|
+
def __ne__(self, other):
|
114
|
+
"""Returns true if both objects are not equal"""
|
115
|
+
return not self == other
|
@@ -111,7 +111,7 @@ class OpenGaussInstanceRequest:
|
|
111
111
|
:type sharding_num: int
|
112
112
|
:param coordinator_num: 仅分布式形态需要填写该参数。协调节点数量,取值范围1~9。CN数量必须小于或等于两倍的分片数。
|
113
113
|
:type coordinator_num: int
|
114
|
-
:param replica_num: 实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
114
|
+
:param replica_num: 实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
115
115
|
:type replica_num: int
|
116
116
|
:param enable_force_switch: enable_force_switch表示是否开启备机强升主功能,enable_force_switch=true表示开启备机强升主功能,enable_force_switch=false表示关闭,默认关闭。仅支持1.2.2及以上版本。 说明: 备机强升主功能适用场景:在主机发生故障后,为了保障集群的可用性,强制拉起备机作为新主机对外提供服务的场景。 本功能在集群故障状态下,以丢失部分数据为代价换取集群尽可能快的恢复服务。本功能是集群状态为不可用时的一个逃生方法,如果操作者不清楚备机强升后丢失数据对业务的影响,请勿使用本功能。 备机强升主相关介绍请参考《故障处理》备机强升主章节。
|
117
117
|
:type enable_force_switch: bool
|
@@ -601,7 +601,7 @@ class OpenGaussInstanceRequest:
|
|
601
601
|
def replica_num(self):
|
602
602
|
"""Gets the replica_num of this OpenGaussInstanceRequest.
|
603
603
|
|
604
|
-
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
604
|
+
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
605
605
|
|
606
606
|
:return: The replica_num of this OpenGaussInstanceRequest.
|
607
607
|
:rtype: int
|
@@ -612,7 +612,7 @@ class OpenGaussInstanceRequest:
|
|
612
612
|
def replica_num(self, replica_num):
|
613
613
|
"""Sets the replica_num of this OpenGaussInstanceRequest.
|
614
614
|
|
615
|
-
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
615
|
+
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
616
616
|
|
617
617
|
:param replica_num: The replica_num of this OpenGaussInstanceRequest.
|
618
618
|
:type replica_num: int
|
@@ -113,7 +113,7 @@ class OpenGaussInstanceRequestBody:
|
|
113
113
|
:type sharding_num: int
|
114
114
|
:param coordinator_num: 仅分布式形态需要填写该参数。协调节点数量,取值范围1~9。CN数量必须小于或等于两倍的分片数。
|
115
115
|
:type coordinator_num: int
|
116
|
-
:param replica_num: 实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
116
|
+
:param replica_num: 实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
117
117
|
:type replica_num: int
|
118
118
|
:param enable_force_switch: enable_force_switch表示是否开启备机强升主功能,enable_force_switch=true表示开启备机强升主功能,enable_force_switch=false表示关闭,默认关闭。仅支持1.2.2及以上版本。 说明: 备机强升主功能适用场景:在主机发生故障后,为了保障集群的可用性,强制拉起备机作为新主机对外提供服务的场景。 本功能在集群故障状态下,以丢失部分数据为代价换取集群尽可能快的恢复服务。本功能是集群状态为不可用时的一个逃生方法,如果操作者不清楚备机强升后丢失数据对业务的影响,请勿使用本功能。 备机强升主相关介绍请参考《故障处理》备机强升主章节。
|
119
119
|
:type enable_force_switch: bool
|
@@ -608,7 +608,7 @@ class OpenGaussInstanceRequestBody:
|
|
608
608
|
def replica_num(self):
|
609
609
|
"""Gets the replica_num of this OpenGaussInstanceRequestBody.
|
610
610
|
|
611
|
-
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
611
|
+
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
612
612
|
|
613
613
|
:return: The replica_num of this OpenGaussInstanceRequestBody.
|
614
614
|
:rtype: int
|
@@ -619,7 +619,7 @@ class OpenGaussInstanceRequestBody:
|
|
619
619
|
def replica_num(self, replica_num):
|
620
620
|
"""Sets the replica_num of this OpenGaussInstanceRequestBody.
|
621
621
|
|
622
|
-
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
622
|
+
实例副本数,支持取值3。不填默认为3。仅支持1.3.0及以上版本的实例。
|
623
623
|
|
624
624
|
:param replica_num: The replica_num of this OpenGaussInstanceRequestBody.
|
625
625
|
:type replica_num: int
|
@@ -0,0 +1,168 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
6
|
+
|
7
|
+
|
8
|
+
class SetNewBackupPolicyRequest:
|
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
|
+
'x_language': 'str',
|
21
|
+
'instance_id': 'str',
|
22
|
+
'body': 'SetNewBackupPolicyRequestBody'
|
23
|
+
}
|
24
|
+
|
25
|
+
attribute_map = {
|
26
|
+
'x_language': 'X-Language',
|
27
|
+
'instance_id': 'instance_id',
|
28
|
+
'body': 'body'
|
29
|
+
}
|
30
|
+
|
31
|
+
def __init__(self, x_language=None, instance_id=None, body=None):
|
32
|
+
"""SetNewBackupPolicyRequest
|
33
|
+
|
34
|
+
The model defined in huaweicloud sdk
|
35
|
+
|
36
|
+
:param x_language: 语言
|
37
|
+
:type x_language: str
|
38
|
+
:param instance_id: 实例ID,严格匹配UUID规则。
|
39
|
+
:type instance_id: str
|
40
|
+
:param body: Body of the SetNewBackupPolicyRequest
|
41
|
+
:type body: :class:`huaweicloudsdkgaussdbforopengauss.v3.SetNewBackupPolicyRequestBody`
|
42
|
+
"""
|
43
|
+
|
44
|
+
|
45
|
+
|
46
|
+
self._x_language = None
|
47
|
+
self._instance_id = None
|
48
|
+
self._body = None
|
49
|
+
self.discriminator = None
|
50
|
+
|
51
|
+
if x_language is not None:
|
52
|
+
self.x_language = x_language
|
53
|
+
self.instance_id = instance_id
|
54
|
+
if body is not None:
|
55
|
+
self.body = body
|
56
|
+
|
57
|
+
@property
|
58
|
+
def x_language(self):
|
59
|
+
"""Gets the x_language of this SetNewBackupPolicyRequest.
|
60
|
+
|
61
|
+
语言
|
62
|
+
|
63
|
+
:return: The x_language of this SetNewBackupPolicyRequest.
|
64
|
+
:rtype: str
|
65
|
+
"""
|
66
|
+
return self._x_language
|
67
|
+
|
68
|
+
@x_language.setter
|
69
|
+
def x_language(self, x_language):
|
70
|
+
"""Sets the x_language of this SetNewBackupPolicyRequest.
|
71
|
+
|
72
|
+
语言
|
73
|
+
|
74
|
+
:param x_language: The x_language of this SetNewBackupPolicyRequest.
|
75
|
+
:type x_language: str
|
76
|
+
"""
|
77
|
+
self._x_language = x_language
|
78
|
+
|
79
|
+
@property
|
80
|
+
def instance_id(self):
|
81
|
+
"""Gets the instance_id of this SetNewBackupPolicyRequest.
|
82
|
+
|
83
|
+
实例ID,严格匹配UUID规则。
|
84
|
+
|
85
|
+
:return: The instance_id of this SetNewBackupPolicyRequest.
|
86
|
+
:rtype: str
|
87
|
+
"""
|
88
|
+
return self._instance_id
|
89
|
+
|
90
|
+
@instance_id.setter
|
91
|
+
def instance_id(self, instance_id):
|
92
|
+
"""Sets the instance_id of this SetNewBackupPolicyRequest.
|
93
|
+
|
94
|
+
实例ID,严格匹配UUID规则。
|
95
|
+
|
96
|
+
:param instance_id: The instance_id of this SetNewBackupPolicyRequest.
|
97
|
+
:type instance_id: str
|
98
|
+
"""
|
99
|
+
self._instance_id = instance_id
|
100
|
+
|
101
|
+
@property
|
102
|
+
def body(self):
|
103
|
+
"""Gets the body of this SetNewBackupPolicyRequest.
|
104
|
+
|
105
|
+
:return: The body of this SetNewBackupPolicyRequest.
|
106
|
+
:rtype: :class:`huaweicloudsdkgaussdbforopengauss.v3.SetNewBackupPolicyRequestBody`
|
107
|
+
"""
|
108
|
+
return self._body
|
109
|
+
|
110
|
+
@body.setter
|
111
|
+
def body(self, body):
|
112
|
+
"""Sets the body of this SetNewBackupPolicyRequest.
|
113
|
+
|
114
|
+
:param body: The body of this SetNewBackupPolicyRequest.
|
115
|
+
:type body: :class:`huaweicloudsdkgaussdbforopengauss.v3.SetNewBackupPolicyRequestBody`
|
116
|
+
"""
|
117
|
+
self._body = body
|
118
|
+
|
119
|
+
def to_dict(self):
|
120
|
+
"""Returns the model properties as a dict"""
|
121
|
+
result = {}
|
122
|
+
|
123
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
124
|
+
value = getattr(self, attr)
|
125
|
+
if isinstance(value, list):
|
126
|
+
result[attr] = list(map(
|
127
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
128
|
+
value
|
129
|
+
))
|
130
|
+
elif hasattr(value, "to_dict"):
|
131
|
+
result[attr] = value.to_dict()
|
132
|
+
elif isinstance(value, dict):
|
133
|
+
result[attr] = dict(map(
|
134
|
+
lambda item: (item[0], item[1].to_dict())
|
135
|
+
if hasattr(item[1], "to_dict") else item,
|
136
|
+
value.items()
|
137
|
+
))
|
138
|
+
else:
|
139
|
+
if attr in self.sensitive_list:
|
140
|
+
result[attr] = "****"
|
141
|
+
else:
|
142
|
+
result[attr] = value
|
143
|
+
|
144
|
+
return result
|
145
|
+
|
146
|
+
def to_str(self):
|
147
|
+
"""Returns the string representation of the model"""
|
148
|
+
import simplejson as json
|
149
|
+
if six.PY2:
|
150
|
+
import sys
|
151
|
+
reload(sys)
|
152
|
+
sys.setdefaultencoding("utf-8")
|
153
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
154
|
+
|
155
|
+
def __repr__(self):
|
156
|
+
"""For `print`"""
|
157
|
+
return self.to_str()
|
158
|
+
|
159
|
+
def __eq__(self, other):
|
160
|
+
"""Returns true if both objects are equal"""
|
161
|
+
if not isinstance(other, SetNewBackupPolicyRequest):
|
162
|
+
return False
|
163
|
+
|
164
|
+
return self.__dict__ == other.__dict__
|
165
|
+
|
166
|
+
def __ne__(self, other):
|
167
|
+
"""Returns true if both objects are not equal"""
|
168
|
+
return not self == other
|
@@ -0,0 +1,110 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
6
|
+
|
7
|
+
|
8
|
+
class SetNewBackupPolicyRequestBody:
|
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
|
+
'backup_policy': 'BackupPolicyInfo'
|
21
|
+
}
|
22
|
+
|
23
|
+
attribute_map = {
|
24
|
+
'backup_policy': 'backup_policy'
|
25
|
+
}
|
26
|
+
|
27
|
+
def __init__(self, backup_policy=None):
|
28
|
+
"""SetNewBackupPolicyRequestBody
|
29
|
+
|
30
|
+
The model defined in huaweicloud sdk
|
31
|
+
|
32
|
+
:param backup_policy:
|
33
|
+
:type backup_policy: :class:`huaweicloudsdkgaussdbforopengauss.v3.BackupPolicyInfo`
|
34
|
+
"""
|
35
|
+
|
36
|
+
|
37
|
+
|
38
|
+
self._backup_policy = None
|
39
|
+
self.discriminator = None
|
40
|
+
|
41
|
+
self.backup_policy = backup_policy
|
42
|
+
|
43
|
+
@property
|
44
|
+
def backup_policy(self):
|
45
|
+
"""Gets the backup_policy of this SetNewBackupPolicyRequestBody.
|
46
|
+
|
47
|
+
:return: The backup_policy of this SetNewBackupPolicyRequestBody.
|
48
|
+
:rtype: :class:`huaweicloudsdkgaussdbforopengauss.v3.BackupPolicyInfo`
|
49
|
+
"""
|
50
|
+
return self._backup_policy
|
51
|
+
|
52
|
+
@backup_policy.setter
|
53
|
+
def backup_policy(self, backup_policy):
|
54
|
+
"""Sets the backup_policy of this SetNewBackupPolicyRequestBody.
|
55
|
+
|
56
|
+
:param backup_policy: The backup_policy of this SetNewBackupPolicyRequestBody.
|
57
|
+
:type backup_policy: :class:`huaweicloudsdkgaussdbforopengauss.v3.BackupPolicyInfo`
|
58
|
+
"""
|
59
|
+
self._backup_policy = backup_policy
|
60
|
+
|
61
|
+
def to_dict(self):
|
62
|
+
"""Returns the model properties as a dict"""
|
63
|
+
result = {}
|
64
|
+
|
65
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
66
|
+
value = getattr(self, attr)
|
67
|
+
if isinstance(value, list):
|
68
|
+
result[attr] = list(map(
|
69
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
70
|
+
value
|
71
|
+
))
|
72
|
+
elif hasattr(value, "to_dict"):
|
73
|
+
result[attr] = value.to_dict()
|
74
|
+
elif isinstance(value, dict):
|
75
|
+
result[attr] = dict(map(
|
76
|
+
lambda item: (item[0], item[1].to_dict())
|
77
|
+
if hasattr(item[1], "to_dict") else item,
|
78
|
+
value.items()
|
79
|
+
))
|
80
|
+
else:
|
81
|
+
if attr in self.sensitive_list:
|
82
|
+
result[attr] = "****"
|
83
|
+
else:
|
84
|
+
result[attr] = value
|
85
|
+
|
86
|
+
return result
|
87
|
+
|
88
|
+
def to_str(self):
|
89
|
+
"""Returns the string representation of the model"""
|
90
|
+
import simplejson as json
|
91
|
+
if six.PY2:
|
92
|
+
import sys
|
93
|
+
reload(sys)
|
94
|
+
sys.setdefaultencoding("utf-8")
|
95
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
96
|
+
|
97
|
+
def __repr__(self):
|
98
|
+
"""For `print`"""
|
99
|
+
return self.to_str()
|
100
|
+
|
101
|
+
def __eq__(self, other):
|
102
|
+
"""Returns true if both objects are equal"""
|
103
|
+
if not isinstance(other, SetNewBackupPolicyRequestBody):
|
104
|
+
return False
|
105
|
+
|
106
|
+
return self.__dict__ == other.__dict__
|
107
|
+
|
108
|
+
def __ne__(self, other):
|
109
|
+
"""Returns true if both objects are not equal"""
|
110
|
+
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 SetNewBackupPolicyResponse(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
|
+
"""SetNewBackupPolicyResponse
|
28
|
+
|
29
|
+
The model defined in huaweicloud sdk
|
30
|
+
|
31
|
+
"""
|
32
|
+
|
33
|
+
super(SetNewBackupPolicyResponse, 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, SetNewBackupPolicyResponse):
|
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
|
@@ -0,0 +1,140 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
import six
|
4
|
+
|
5
|
+
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
|
6
|
+
|
7
|
+
|
8
|
+
class ShowBatchUpgradeCandidateVersionsRequest:
|
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
|
+
'x_language': 'str',
|
21
|
+
'body': 'UpgradeInstancesRequestBody'
|
22
|
+
}
|
23
|
+
|
24
|
+
attribute_map = {
|
25
|
+
'x_language': 'X-Language',
|
26
|
+
'body': 'body'
|
27
|
+
}
|
28
|
+
|
29
|
+
def __init__(self, x_language=None, body=None):
|
30
|
+
"""ShowBatchUpgradeCandidateVersionsRequest
|
31
|
+
|
32
|
+
The model defined in huaweicloud sdk
|
33
|
+
|
34
|
+
:param x_language: 语言[zh-cn, en-us]
|
35
|
+
:type x_language: str
|
36
|
+
:param body: Body of the ShowBatchUpgradeCandidateVersionsRequest
|
37
|
+
:type body: :class:`huaweicloudsdkgaussdbforopengauss.v3.UpgradeInstancesRequestBody`
|
38
|
+
"""
|
39
|
+
|
40
|
+
|
41
|
+
|
42
|
+
self._x_language = None
|
43
|
+
self._body = None
|
44
|
+
self.discriminator = None
|
45
|
+
|
46
|
+
if x_language is not None:
|
47
|
+
self.x_language = x_language
|
48
|
+
if body is not None:
|
49
|
+
self.body = body
|
50
|
+
|
51
|
+
@property
|
52
|
+
def x_language(self):
|
53
|
+
"""Gets the x_language of this ShowBatchUpgradeCandidateVersionsRequest.
|
54
|
+
|
55
|
+
语言[zh-cn, en-us]
|
56
|
+
|
57
|
+
:return: The x_language of this ShowBatchUpgradeCandidateVersionsRequest.
|
58
|
+
:rtype: str
|
59
|
+
"""
|
60
|
+
return self._x_language
|
61
|
+
|
62
|
+
@x_language.setter
|
63
|
+
def x_language(self, x_language):
|
64
|
+
"""Sets the x_language of this ShowBatchUpgradeCandidateVersionsRequest.
|
65
|
+
|
66
|
+
语言[zh-cn, en-us]
|
67
|
+
|
68
|
+
:param x_language: The x_language of this ShowBatchUpgradeCandidateVersionsRequest.
|
69
|
+
:type x_language: str
|
70
|
+
"""
|
71
|
+
self._x_language = x_language
|
72
|
+
|
73
|
+
@property
|
74
|
+
def body(self):
|
75
|
+
"""Gets the body of this ShowBatchUpgradeCandidateVersionsRequest.
|
76
|
+
|
77
|
+
:return: The body of this ShowBatchUpgradeCandidateVersionsRequest.
|
78
|
+
:rtype: :class:`huaweicloudsdkgaussdbforopengauss.v3.UpgradeInstancesRequestBody`
|
79
|
+
"""
|
80
|
+
return self._body
|
81
|
+
|
82
|
+
@body.setter
|
83
|
+
def body(self, body):
|
84
|
+
"""Sets the body of this ShowBatchUpgradeCandidateVersionsRequest.
|
85
|
+
|
86
|
+
:param body: The body of this ShowBatchUpgradeCandidateVersionsRequest.
|
87
|
+
:type body: :class:`huaweicloudsdkgaussdbforopengauss.v3.UpgradeInstancesRequestBody`
|
88
|
+
"""
|
89
|
+
self._body = body
|
90
|
+
|
91
|
+
def to_dict(self):
|
92
|
+
"""Returns the model properties as a dict"""
|
93
|
+
result = {}
|
94
|
+
|
95
|
+
for attr, _ in six.iteritems(self.openapi_types):
|
96
|
+
value = getattr(self, attr)
|
97
|
+
if isinstance(value, list):
|
98
|
+
result[attr] = list(map(
|
99
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
100
|
+
value
|
101
|
+
))
|
102
|
+
elif hasattr(value, "to_dict"):
|
103
|
+
result[attr] = value.to_dict()
|
104
|
+
elif isinstance(value, dict):
|
105
|
+
result[attr] = dict(map(
|
106
|
+
lambda item: (item[0], item[1].to_dict())
|
107
|
+
if hasattr(item[1], "to_dict") else item,
|
108
|
+
value.items()
|
109
|
+
))
|
110
|
+
else:
|
111
|
+
if attr in self.sensitive_list:
|
112
|
+
result[attr] = "****"
|
113
|
+
else:
|
114
|
+
result[attr] = value
|
115
|
+
|
116
|
+
return result
|
117
|
+
|
118
|
+
def to_str(self):
|
119
|
+
"""Returns the string representation of the model"""
|
120
|
+
import simplejson as json
|
121
|
+
if six.PY2:
|
122
|
+
import sys
|
123
|
+
reload(sys)
|
124
|
+
sys.setdefaultencoding("utf-8")
|
125
|
+
return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
|
126
|
+
|
127
|
+
def __repr__(self):
|
128
|
+
"""For `print`"""
|
129
|
+
return self.to_str()
|
130
|
+
|
131
|
+
def __eq__(self, other):
|
132
|
+
"""Returns true if both objects are equal"""
|
133
|
+
if not isinstance(other, ShowBatchUpgradeCandidateVersionsRequest):
|
134
|
+
return False
|
135
|
+
|
136
|
+
return self.__dict__ == other.__dict__
|
137
|
+
|
138
|
+
def __ne__(self, other):
|
139
|
+
"""Returns true if both objects are not equal"""
|
140
|
+
return not self == other
|