Skip to content

Commit 24cbc0e

Browse files
committed
Support Nacos Config.
1 parent 377698f commit 24cbc0e

File tree

69 files changed

+3665
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+3665
-0
lines changed

aliyun-python-sdk-mse/ChangeLog.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2021-03-31 Version: 2.7.0
2+
- Support Nacos Config.
3+

aliyun-python-sdk-mse/LICENSE

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
Copyright 1999-present Alibaba Group Holding Ltd.
2+
3+
Licensed under the Apache License, Version 2.0 (the "License");
4+
you may not use this file except in compliance with the License.
5+
You may obtain a copy of the License at
6+
7+
http://www.apache.org/licenses/LICENSE-2.0
8+
9+
Unless required by applicable law or agreed to in writing, software
10+
distributed under the License is distributed on an "AS IS" BASIS,
11+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
See the License for the specific language governing permissions and
13+
limitations under the License.

aliyun-python-sdk-mse/MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
include LICENSE README.rst ChangeLog.txt

aliyun-python-sdk-mse/README.rst

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
=============================================================
2+
aliyun-python-sdk-mse
3+
=============================================================
4+
5+
.. This is the mse module of Aliyun Python SDK.
6+
7+
Aliyun Python SDK is the official software development kit. It makes things easy to integrate your Python application, library, or script with Aliyun services.
8+
9+
This module works on Python versions:
10+
11+
2.6.5 and greater
12+
13+
**Documentation:**
14+
15+
Please visit `http://develop.aliyun.com/sdk/python <http://develop.aliyun.com/sdk/python>`_
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
__version__ = '2.7.0'
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
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+
# #
10+
# # http://www.apache.org/licenses/LICENSE-2.0
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+
21+
class EndpointData():
22+
def __init__(self):
23+
self.endpoint_map = {}
24+
self.endpoint_regional = "regional"
25+
26+
def getEndpointMap(self):
27+
return self.endpoint_map
28+
29+
def getEndpointRegional(self):
30+
return self.endpoint_regional
31+
32+
33+
endpoint_data = EndpointData()

aliyun-python-sdk-mse/aliyunsdkmse/request/__init__.py

Whitespace-only changes.
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
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+
#
10+
# http://www.apache.org/licenses/LICENSE-2.0
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+
from aliyunsdkmse.endpoint import endpoint_data
22+
23+
class AddMockRuleRequest(RpcRequest):
24+
25+
def __init__(self):
26+
RpcRequest.__init__(self, 'mse', '2019-05-31', 'AddMockRule','mse')
27+
self.set_method('POST')
28+
if hasattr(self, "endpoint_map"):
29+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
30+
if hasattr(self, "endpoint_regional"):
31+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
32+
33+
34+
def get_ExtraJson(self):
35+
return self.get_query_params().get('ExtraJson')
36+
37+
def set_ExtraJson(self,ExtraJson):
38+
self.add_query_param('ExtraJson',ExtraJson)
39+
40+
def get_ProviderAppId(self):
41+
return self.get_query_params().get('ProviderAppId')
42+
43+
def set_ProviderAppId(self,ProviderAppId):
44+
self.add_query_param('ProviderAppId',ProviderAppId)
45+
46+
def get_Source(self):
47+
return self.get_query_params().get('Source')
48+
49+
def set_Source(self,Source):
50+
self.add_query_param('Source',Source)
51+
52+
def get_Enable(self):
53+
return self.get_query_params().get('Enable')
54+
55+
def set_Enable(self,Enable):
56+
self.add_query_param('Enable',Enable)
57+
58+
def get_ScMockItems(self):
59+
return self.get_query_params().get('ScMockItems')
60+
61+
def set_ScMockItems(self,ScMockItems):
62+
self.add_query_param('ScMockItems',ScMockItems)
63+
64+
def get_ProviderAppName(self):
65+
return self.get_query_params().get('ProviderAppName')
66+
67+
def set_ProviderAppName(self,ProviderAppName):
68+
self.add_query_param('ProviderAppName',ProviderAppName)
69+
70+
def get_ConsumerAppIds(self):
71+
return self.get_query_params().get('ConsumerAppIds')
72+
73+
def set_ConsumerAppIds(self,ConsumerAppIds):
74+
self.add_query_param('ConsumerAppIds',ConsumerAppIds)
75+
76+
def get_DubboMockItems(self):
77+
return self.get_query_params().get('DubboMockItems')
78+
79+
def set_DubboMockItems(self,DubboMockItems):
80+
self.add_query_param('DubboMockItems',DubboMockItems)
81+
82+
def get_Name(self):
83+
return self.get_query_params().get('Name')
84+
85+
def set_Name(self,Name):
86+
self.add_query_param('Name',Name)
87+
88+
def get_Region(self):
89+
return self.get_query_params().get('Region')
90+
91+
def set_Region(self,Region):
92+
self.add_query_param('Region',Region)
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
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+
#
10+
# http://www.apache.org/licenses/LICENSE-2.0
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+
from aliyunsdkmse.endpoint import endpoint_data
22+
23+
class CloneNacosConfigRequest(RpcRequest):
24+
25+
def __init__(self):
26+
RpcRequest.__init__(self, 'mse', '2019-05-31', 'CloneNacosConfig','mse')
27+
self.set_method('POST')
28+
if hasattr(self, "endpoint_map"):
29+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
30+
if hasattr(self, "endpoint_regional"):
31+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
32+
33+
34+
def get_TargetNamespaceId(self):
35+
return self.get_query_params().get('TargetNamespaceId')
36+
37+
def set_TargetNamespaceId(self,TargetNamespaceId):
38+
self.add_query_param('TargetNamespaceId',TargetNamespaceId)
39+
40+
def get_InstanceId(self):
41+
return self.get_query_params().get('InstanceId')
42+
43+
def set_InstanceId(self,InstanceId):
44+
self.add_query_param('InstanceId',InstanceId)
45+
46+
def get_Ids(self):
47+
return self.get_query_params().get('Ids')
48+
49+
def set_Ids(self,Ids):
50+
self.add_query_param('Ids',Ids)
51+
52+
def get_OriginNamespaceId(self):
53+
return self.get_query_params().get('OriginNamespaceId')
54+
55+
def set_OriginNamespaceId(self,OriginNamespaceId):
56+
self.add_query_param('OriginNamespaceId',OriginNamespaceId)
57+
58+
def get_Policy(self):
59+
return self.get_query_params().get('Policy')
60+
61+
def set_Policy(self,Policy):
62+
self.add_query_param('Policy',Policy)
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
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+
#
10+
# http://www.apache.org/licenses/LICENSE-2.0
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+
from aliyunsdkmse.endpoint import endpoint_data
22+
23+
class CreateAlarmRuleRequest(RpcRequest):
24+
25+
def __init__(self):
26+
RpcRequest.__init__(self, 'mse', '2019-05-31', 'CreateAlarmRule','mse')
27+
self.set_method('POST')
28+
if hasattr(self, "endpoint_map"):
29+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
30+
if hasattr(self, "endpoint_regional"):
31+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
32+
33+
34+
def get_NValue(self):
35+
return self.get_query_params().get('NValue')
36+
37+
def set_NValue(self,NValue):
38+
self.add_query_param('NValue',NValue)
39+
40+
def get_AlarmItem(self):
41+
return self.get_query_params().get('AlarmItem')
42+
43+
def set_AlarmItem(self,AlarmItem):
44+
self.add_query_param('AlarmItem',AlarmItem)
45+
46+
def get_Operator(self):
47+
return self.get_query_params().get('Operator')
48+
49+
def set_Operator(self,Operator):
50+
self.add_query_param('Operator',Operator)
51+
52+
def get_AlarmAliasName(self):
53+
return self.get_query_params().get('AlarmAliasName')
54+
55+
def set_AlarmAliasName(self,AlarmAliasName):
56+
self.add_query_param('AlarmAliasName',AlarmAliasName)
57+
58+
def get_InstanceId(self):
59+
return self.get_query_params().get('InstanceId')
60+
61+
def set_InstanceId(self,InstanceId):
62+
self.add_query_param('InstanceId',InstanceId)
63+
64+
def get_ContactGroupIds(self):
65+
return self.get_query_params().get('ContactGroupIds')
66+
67+
def set_ContactGroupIds(self,ContactGroupIds):
68+
self.add_query_param('ContactGroupIds',ContactGroupIds)
69+
70+
def get_AlertWay(self):
71+
return self.get_query_params().get('AlertWay')
72+
73+
def set_AlertWay(self,AlertWay):
74+
self.add_query_param('AlertWay',AlertWay)
75+
76+
def get_Aggregates(self):
77+
return self.get_query_params().get('Aggregates')
78+
79+
def set_Aggregates(self,Aggregates):
80+
self.add_query_param('Aggregates',Aggregates)
81+
82+
def get_Value(self):
83+
return self.get_query_params().get('Value')
84+
85+
def set_Value(self,Value):
86+
self.add_query_param('Value',Value)

0 commit comments

Comments
 (0)