Skip to content

Commit 42e705a

Browse files
committed
Update Endpoint.
1 parent 309a47b commit 42e705a

28 files changed

+212
-26
lines changed

aliyun-python-sdk-gwlb/ChangeLog.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
2024-10-23 Version: 1.0.2
2+
- Update Endpoint.
3+
14
2024-10-18 Version: 1.0.1
25
- Gwlb Open API released.
36

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = '1.0.1'
1+
__version__ = '1.0.2'
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-gwlb/aliyunsdkgwlb/request/v20240415/AddServersToServerGroupRequest.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@
1818
# under the License.
1919

2020
from aliyunsdkcore.request import RpcRequest
21+
from aliyunsdkgwlb.endpoint import endpoint_data
2122

2223
class AddServersToServerGroupRequest(RpcRequest):
2324

2425
def __init__(self):
25-
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'AddServersToServerGroup')
26+
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'AddServersToServerGroup','gwlb')
2627
self.set_protocol_type('https')
2728
self.set_method('POST')
29+
30+
if hasattr(self, "endpoint_map"):
31+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
32+
if hasattr(self, "endpoint_regional"):
33+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
2834

2935
def get_ClientToken(self): # String
3036
return self.get_body_params().get('ClientToken')

aliyun-python-sdk-gwlb/aliyunsdkgwlb/request/v20240415/CreateListenerRequest.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@
1818
# under the License.
1919

2020
from aliyunsdkcore.request import RpcRequest
21+
from aliyunsdkgwlb.endpoint import endpoint_data
2122

2223
class CreateListenerRequest(RpcRequest):
2324

2425
def __init__(self):
25-
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'CreateListener')
26+
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'CreateListener','gwlb')
2627
self.set_protocol_type('https')
2728
self.set_method('POST')
29+
30+
if hasattr(self, "endpoint_map"):
31+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
32+
if hasattr(self, "endpoint_regional"):
33+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
2834

2935
def get_ClientToken(self): # String
3036
return self.get_body_params().get('ClientToken')

aliyun-python-sdk-gwlb/aliyunsdkgwlb/request/v20240415/CreateLoadBalancerRequest.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@
1818
# under the License.
1919

2020
from aliyunsdkcore.request import RpcRequest
21+
from aliyunsdkgwlb.endpoint import endpoint_data
2122

2223
class CreateLoadBalancerRequest(RpcRequest):
2324

2425
def __init__(self):
25-
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'CreateLoadBalancer')
26+
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'CreateLoadBalancer','gwlb')
2627
self.set_protocol_type('https')
2728
self.set_method('POST')
29+
30+
if hasattr(self, "endpoint_map"):
31+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
32+
if hasattr(self, "endpoint_regional"):
33+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
2834

2935
def get_ClientToken(self): # String
3036
return self.get_body_params().get('ClientToken')

aliyun-python-sdk-gwlb/aliyunsdkgwlb/request/v20240415/CreateServerGroupRequest.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@
1818
# under the License.
1919

2020
from aliyunsdkcore.request import RpcRequest
21+
from aliyunsdkgwlb.endpoint import endpoint_data
2122

2223
class CreateServerGroupRequest(RpcRequest):
2324

2425
def __init__(self):
25-
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'CreateServerGroup')
26+
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'CreateServerGroup','gwlb')
2627
self.set_protocol_type('https')
2728
self.set_method('POST')
29+
30+
if hasattr(self, "endpoint_map"):
31+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
32+
if hasattr(self, "endpoint_regional"):
33+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
2834

2935
def get_ServerGroupName(self): # String
3036
return self.get_body_params().get('ServerGroupName')

aliyun-python-sdk-gwlb/aliyunsdkgwlb/request/v20240415/DeleteListenerRequest.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@
1818
# under the License.
1919

2020
from aliyunsdkcore.request import RpcRequest
21+
from aliyunsdkgwlb.endpoint import endpoint_data
2122

2223
class DeleteListenerRequest(RpcRequest):
2324

2425
def __init__(self):
25-
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'DeleteListener')
26+
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'DeleteListener','gwlb')
2627
self.set_protocol_type('https')
2728
self.set_method('POST')
29+
30+
if hasattr(self, "endpoint_map"):
31+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
32+
if hasattr(self, "endpoint_regional"):
33+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
2834

2935
def get_ClientToken(self): # String
3036
return self.get_body_params().get('ClientToken')

aliyun-python-sdk-gwlb/aliyunsdkgwlb/request/v20240415/DeleteLoadBalancerRequest.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@
1818
# under the License.
1919

2020
from aliyunsdkcore.request import RpcRequest
21+
from aliyunsdkgwlb.endpoint import endpoint_data
2122

2223
class DeleteLoadBalancerRequest(RpcRequest):
2324

2425
def __init__(self):
25-
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'DeleteLoadBalancer')
26+
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'DeleteLoadBalancer','gwlb')
2627
self.set_protocol_type('https')
2728
self.set_method('POST')
29+
30+
if hasattr(self, "endpoint_map"):
31+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
32+
if hasattr(self, "endpoint_regional"):
33+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
2834

2935
def get_ClientToken(self): # String
3036
return self.get_body_params().get('ClientToken')

aliyun-python-sdk-gwlb/aliyunsdkgwlb/request/v20240415/DeleteServerGroupRequest.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@
1818
# under the License.
1919

2020
from aliyunsdkcore.request import RpcRequest
21+
from aliyunsdkgwlb.endpoint import endpoint_data
2122

2223
class DeleteServerGroupRequest(RpcRequest):
2324

2425
def __init__(self):
25-
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'DeleteServerGroup')
26+
RpcRequest.__init__(self, 'Gwlb', '2024-04-15', 'DeleteServerGroup','gwlb')
2627
self.set_protocol_type('https')
2728
self.set_method('POST')
29+
30+
if hasattr(self, "endpoint_map"):
31+
setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
32+
if hasattr(self, "endpoint_regional"):
33+
setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())
2834

2935
def get_ClientToken(self): # String
3036
return self.get_body_params().get('ClientToken')

0 commit comments

Comments
 (0)