Skip to content

Commit 9b6f9f8

Browse files
committed
POLARDB SDK Auto Released By zhigang.xzg,Version:1.4.0
发布日志: 1, Add CreateDBCluster interface; 2, Add CreateDBNodes interface;
1 parent 4c4e859 commit 9b6f9f8

File tree

5 files changed

+269
-1
lines changed

5 files changed

+269
-1
lines changed

aliyun-python-sdk-polardb/ChangeLog.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
2019-04-22 Version: 1.4.0
2+
1, Add CreateDBCluster interface;
3+
2, Add CreateDBNodes interface;
4+
15
2019-02-26 Version: 1.3.0
26
1, Add interface of tag.
37
2, Add tag info in DescribeDBClusters and DescribeDBClusterAttribute.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "1.3.0"
1+
__version__ = "1.4.0"
Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
#
12+
#
13+
# Unless required by applicable law or agreed to in writing,
14+
# software distributed under the License is distributed on an
15+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16+
# KIND, either express or implied. See the License for the
17+
# specific language governing permissions and limitations
18+
# under the License.
19+
20+
from aliyunsdkcore.request import RpcRequest
21+
class CreateDBClusterRequest(RpcRequest):
22+
23+
def __init__(self):
24+
RpcRequest.__init__(self, 'polardb', '2017-08-01', 'CreateDBCluster','polardb')
25+
26+
def get_ResourceOwnerId(self):
27+
return self.get_query_params().get('ResourceOwnerId')
28+
29+
def set_ResourceOwnerId(self,ResourceOwnerId):
30+
self.add_query_param('ResourceOwnerId',ResourceOwnerId)
31+
32+
def get_DBClusterDescription(self):
33+
return self.get_query_params().get('DBClusterDescription')
34+
35+
def set_DBClusterDescription(self,DBClusterDescription):
36+
self.add_query_param('DBClusterDescription',DBClusterDescription)
37+
38+
def get_Period(self):
39+
return self.get_query_params().get('Period')
40+
41+
def set_Period(self,Period):
42+
self.add_query_param('Period',Period)
43+
44+
def get_ResourceOwnerAccount(self):
45+
return self.get_query_params().get('ResourceOwnerAccount')
46+
47+
def set_ResourceOwnerAccount(self,ResourceOwnerAccount):
48+
self.add_query_param('ResourceOwnerAccount',ResourceOwnerAccount)
49+
50+
def get_ClientToken(self):
51+
return self.get_query_params().get('ClientToken')
52+
53+
def set_ClientToken(self,ClientToken):
54+
self.add_query_param('ClientToken',ClientToken)
55+
56+
def get_OwnerAccount(self):
57+
return self.get_query_params().get('OwnerAccount')
58+
59+
def set_OwnerAccount(self,OwnerAccount):
60+
self.add_query_param('OwnerAccount',OwnerAccount)
61+
62+
def get_OwnerId(self):
63+
return self.get_query_params().get('OwnerId')
64+
65+
def set_OwnerId(self,OwnerId):
66+
self.add_query_param('OwnerId',OwnerId)
67+
68+
def get_UsedTime(self):
69+
return self.get_query_params().get('UsedTime')
70+
71+
def set_UsedTime(self,UsedTime):
72+
self.add_query_param('UsedTime',UsedTime)
73+
74+
def get_ClusterNetworkType(self):
75+
return self.get_query_params().get('ClusterNetworkType')
76+
77+
def set_ClusterNetworkType(self,ClusterNetworkType):
78+
self.add_query_param('ClusterNetworkType',ClusterNetworkType)
79+
80+
def get_VSwitchId(self):
81+
return self.get_query_params().get('VSwitchId')
82+
83+
def set_VSwitchId(self,VSwitchId):
84+
self.add_query_param('VSwitchId',VSwitchId)
85+
86+
def get_DBNodeClass(self):
87+
return self.get_query_params().get('DBNodeClass')
88+
89+
def set_DBNodeClass(self,DBNodeClass):
90+
self.add_query_param('DBNodeClass',DBNodeClass)
91+
92+
def get_Engine(self):
93+
return self.get_query_params().get('Engine')
94+
95+
def set_Engine(self,Engine):
96+
self.add_query_param('Engine',Engine)
97+
98+
def get_VPCId(self):
99+
return self.get_query_params().get('VPCId')
100+
101+
def set_VPCId(self,VPCId):
102+
self.add_query_param('VPCId',VPCId)
103+
104+
def get_DBType(self):
105+
return self.get_query_params().get('DBType')
106+
107+
def set_DBType(self,DBType):
108+
self.add_query_param('DBType',DBType)
109+
110+
def get_ZoneId(self):
111+
return self.get_query_params().get('ZoneId')
112+
113+
def set_ZoneId(self,ZoneId):
114+
self.add_query_param('ZoneId',ZoneId)
115+
116+
def get_DBVersion(self):
117+
return self.get_query_params().get('DBVersion')
118+
119+
def set_DBVersion(self,DBVersion):
120+
self.add_query_param('DBVersion',DBVersion)
121+
122+
def get_PayType(self):
123+
return self.get_query_params().get('PayType')
124+
125+
def set_PayType(self,PayType):
126+
self.add_query_param('PayType',PayType)
Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
#
12+
#
13+
# Unless required by applicable law or agreed to in writing,
14+
# software distributed under the License is distributed on an
15+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16+
# KIND, either express or implied. See the License for the
17+
# specific language governing permissions and limitations
18+
# under the License.
19+
20+
from aliyunsdkcore.request import RpcRequest
21+
class CreateDBNodesRequest(RpcRequest):
22+
23+
def __init__(self):
24+
RpcRequest.__init__(self, 'polardb', '2017-08-01', 'CreateDBNodes','polardb')
25+
26+
def get_ResourceOwnerId(self):
27+
return self.get_query_params().get('ResourceOwnerId')
28+
29+
def set_ResourceOwnerId(self,ResourceOwnerId):
30+
self.add_query_param('ResourceOwnerId',ResourceOwnerId)
31+
32+
def get_ResourceOwnerAccount(self):
33+
return self.get_query_params().get('ResourceOwnerAccount')
34+
35+
def set_ResourceOwnerAccount(self,ResourceOwnerAccount):
36+
self.add_query_param('ResourceOwnerAccount',ResourceOwnerAccount)
37+
38+
def get_ClientToken(self):
39+
return self.get_query_params().get('ClientToken')
40+
41+
def set_ClientToken(self,ClientToken):
42+
self.add_query_param('ClientToken',ClientToken)
43+
44+
def get_DBClusterId(self):
45+
return self.get_query_params().get('DBClusterId')
46+
47+
def set_DBClusterId(self,DBClusterId):
48+
self.add_query_param('DBClusterId',DBClusterId)
49+
50+
def get_OwnerAccount(self):
51+
return self.get_query_params().get('OwnerAccount')
52+
53+
def set_OwnerAccount(self,OwnerAccount):
54+
self.add_query_param('OwnerAccount',OwnerAccount)
55+
56+
def get_OwnerId(self):
57+
return self.get_query_params().get('OwnerId')
58+
59+
def set_OwnerId(self,OwnerId):
60+
self.add_query_param('OwnerId',OwnerId)
61+
62+
def get_DBNodes(self):
63+
return self.get_query_params().get('DBNodes')
64+
65+
def set_DBNodes(self,DBNodes):
66+
for i in range(len(DBNodes)):
67+
if DBNodes[i].get('TargetClass') is not None:
68+
self.add_query_param('DBNode.' + str(i + 1) + '.TargetClass' , DBNodes[i].get('TargetClass'))
69+
if DBNodes[i].get('ZoneId') is not None:
70+
self.add_query_param('DBNode.' + str(i + 1) + '.ZoneId' , DBNodes[i].get('ZoneId'))
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
#
12+
#
13+
# Unless required by applicable law or agreed to in writing,
14+
# software distributed under the License is distributed on an
15+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16+
# KIND, either express or implied. See the License for the
17+
# specific language governing permissions and limitations
18+
# under the License.
19+
20+
from aliyunsdkcore.request import RpcRequest
21+
class DeleteDBNodesRequest(RpcRequest):
22+
23+
def __init__(self):
24+
RpcRequest.__init__(self, 'polardb', '2017-08-01', 'DeleteDBNodes','polardb')
25+
26+
def get_ResourceOwnerId(self):
27+
return self.get_query_params().get('ResourceOwnerId')
28+
29+
def set_ResourceOwnerId(self,ResourceOwnerId):
30+
self.add_query_param('ResourceOwnerId',ResourceOwnerId)
31+
32+
def get_DBNodeIds(self):
33+
return self.get_query_params().get('DBNodeIds')
34+
35+
def set_DBNodeIds(self,DBNodeIds):
36+
for i in range(len(DBNodeIds)):
37+
if DBNodeIds[i] is not None:
38+
self.add_query_param('DBNodeId.' + str(i + 1) , DBNodeIds[i]);
39+
40+
def get_ResourceOwnerAccount(self):
41+
return self.get_query_params().get('ResourceOwnerAccount')
42+
43+
def set_ResourceOwnerAccount(self,ResourceOwnerAccount):
44+
self.add_query_param('ResourceOwnerAccount',ResourceOwnerAccount)
45+
46+
def get_ClientToken(self):
47+
return self.get_query_params().get('ClientToken')
48+
49+
def set_ClientToken(self,ClientToken):
50+
self.add_query_param('ClientToken',ClientToken)
51+
52+
def get_DBClusterId(self):
53+
return self.get_query_params().get('DBClusterId')
54+
55+
def set_DBClusterId(self,DBClusterId):
56+
self.add_query_param('DBClusterId',DBClusterId)
57+
58+
def get_OwnerAccount(self):
59+
return self.get_query_params().get('OwnerAccount')
60+
61+
def set_OwnerAccount(self,OwnerAccount):
62+
self.add_query_param('OwnerAccount',OwnerAccount)
63+
64+
def get_OwnerId(self):
65+
return self.get_query_params().get('OwnerId')
66+
67+
def set_OwnerId(self,OwnerId):
68+
self.add_query_param('OwnerId',OwnerId)

0 commit comments

Comments
 (0)