Skip to content

Commit 397ce74

Browse files
author
SDKAuto
committed
CodeGen from PR 15035 in Azure/azure-rest-api-specs
Merge 999788bd2cfe96866769b70df5422cd0d7c96e9c into 0299f51d56542b6214281705ee746bdaea9bffb0
1 parent f3aa604 commit 397ce74

20 files changed

+10867
-2
lines changed

sdk/containerservice/azure-mgmt-containerservice/_meta.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"autorest": "V2",
33
"use": "@microsoft.azure/autorest.python@~4.0.71",
4-
"commit": "1f0bb3f63b1664ace42cfdf646d8b2382d7b7b22",
4+
"commit": "77137db08db5e660b0fea21929543b643eb77640",
55
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
66
"autorest_command": "autorest specification/containerservice/resource-manager/readme.md --keep-version-file --multiapi --no-async --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk [email protected]/autorest.python@~4.0.71 --version=V2",
77
"readme": "specification/containerservice/resource-manager/readme.md"

sdk/containerservice/azure-mgmt-containerservice/azure/mgmt/containerservice/_container_service_client.py

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ def models(cls, api_version=DEFAULT_API_VERSION):
9999
* 2021-02-01: :mod:`v2021_02_01.models<azure.mgmt.containerservice.v2021_02_01.models>`
100100
* 2021-03-01: :mod:`v2021_03_01.models<azure.mgmt.containerservice.v2021_03_01.models>`
101101
* 2021-05-01: :mod:`v2021_05_01.models<azure.mgmt.containerservice.v2021_05_01.models>`
102+
* 2021-05-01: :mod:`v2021_07_01.models<azure.mgmt.containerservice.v2021_07_01.models>`
102103
"""
103104
if api_version == '2017-07-01':
104105
from .v2017_07_01 import models
@@ -175,6 +176,9 @@ def models(cls, api_version=DEFAULT_API_VERSION):
175176
elif api_version == '2021-05-01':
176177
from .v2021_05_01 import models
177178
return models
179+
elif api_version == '2021-05-01':
180+
from .v2021_07_01 import models
181+
return models
178182
raise NotImplementedError("APIVersion {} is not available".format(api_version))
179183

180184
@property
@@ -199,6 +203,7 @@ def agent_pools(self):
199203
* 2021-02-01: :class:`AgentPoolsOperations<azure.mgmt.containerservice.v2021_02_01.operations.AgentPoolsOperations>`
200204
* 2021-03-01: :class:`AgentPoolsOperations<azure.mgmt.containerservice.v2021_03_01.operations.AgentPoolsOperations>`
201205
* 2021-05-01: :class:`AgentPoolsOperations<azure.mgmt.containerservice.v2021_05_01.operations.AgentPoolsOperations>`
206+
* 2021-05-01: :class:`AgentPoolsOperations<azure.mgmt.containerservice.v2021_07_01.operations.AgentPoolsOperations>`
202207
"""
203208
api_version = self._get_api_version('agent_pools')
204209
if api_version == '2019-02-01':
@@ -237,6 +242,8 @@ def agent_pools(self):
237242
from .v2021_03_01.operations import AgentPoolsOperations as OperationClass
238243
elif api_version == '2021-05-01':
239244
from .v2021_05_01.operations import AgentPoolsOperations as OperationClass
245+
elif api_version == '2021-05-01':
246+
from .v2021_07_01.operations import AgentPoolsOperations as OperationClass
240247
else:
241248
raise NotImplementedError("APIVersion {} is not available".format(api_version))
242249
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -262,6 +269,7 @@ def maintenance_configurations(self):
262269
* 2021-02-01: :class:`MaintenanceConfigurationsOperations<azure.mgmt.containerservice.v2021_02_01.operations.MaintenanceConfigurationsOperations>`
263270
* 2021-03-01: :class:`MaintenanceConfigurationsOperations<azure.mgmt.containerservice.v2021_03_01.operations.MaintenanceConfigurationsOperations>`
264271
* 2021-05-01: :class:`MaintenanceConfigurationsOperations<azure.mgmt.containerservice.v2021_05_01.operations.MaintenanceConfigurationsOperations>`
272+
* 2021-05-01: :class:`MaintenanceConfigurationsOperations<azure.mgmt.containerservice.v2021_07_01.operations.MaintenanceConfigurationsOperations>`
265273
"""
266274
api_version = self._get_api_version('maintenance_configurations')
267275
if api_version == '2020-12-01':
@@ -272,6 +280,8 @@ def maintenance_configurations(self):
272280
from .v2021_03_01.operations import MaintenanceConfigurationsOperations as OperationClass
273281
elif api_version == '2021-05-01':
274282
from .v2021_05_01.operations import MaintenanceConfigurationsOperations as OperationClass
283+
elif api_version == '2021-05-01':
284+
from .v2021_07_01.operations import MaintenanceConfigurationsOperations as OperationClass
275285
else:
276286
raise NotImplementedError("APIVersion {} is not available".format(api_version))
277287
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -300,6 +310,7 @@ def managed_clusters(self):
300310
* 2021-02-01: :class:`ManagedClustersOperations<azure.mgmt.containerservice.v2021_02_01.operations.ManagedClustersOperations>`
301311
* 2021-03-01: :class:`ManagedClustersOperations<azure.mgmt.containerservice.v2021_03_01.operations.ManagedClustersOperations>`
302312
* 2021-05-01: :class:`ManagedClustersOperations<azure.mgmt.containerservice.v2021_05_01.operations.ManagedClustersOperations>`
313+
* 2021-05-01: :class:`ManagedClustersOperations<azure.mgmt.containerservice.v2021_07_01.operations.ManagedClustersOperations>`
303314
"""
304315
api_version = self._get_api_version('managed_clusters')
305316
if api_version == '2018-03-31':
@@ -342,6 +353,8 @@ def managed_clusters(self):
342353
from .v2021_03_01.operations import ManagedClustersOperations as OperationClass
343354
elif api_version == '2021-05-01':
344355
from .v2021_05_01.operations import ManagedClustersOperations as OperationClass
356+
elif api_version == '2021-05-01':
357+
from .v2021_07_01.operations import ManagedClustersOperations as OperationClass
345358
else:
346359
raise NotImplementedError("APIVersion {} is not available".format(api_version))
347360
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -392,6 +405,7 @@ def operations(self):
392405
* 2021-02-01: :class:`Operations<azure.mgmt.containerservice.v2021_02_01.operations.Operations>`
393406
* 2021-03-01: :class:`Operations<azure.mgmt.containerservice.v2021_03_01.operations.Operations>`
394407
* 2021-05-01: :class:`Operations<azure.mgmt.containerservice.v2021_05_01.operations.Operations>`
408+
* 2021-05-01: :class:`Operations<azure.mgmt.containerservice.v2021_07_01.operations.Operations>`
395409
"""
396410
api_version = self._get_api_version('operations')
397411
if api_version == '2018-03-31':
@@ -434,6 +448,8 @@ def operations(self):
434448
from .v2021_03_01.operations import Operations as OperationClass
435449
elif api_version == '2021-05-01':
436450
from .v2021_05_01.operations import Operations as OperationClass
451+
elif api_version == '2021-05-01':
452+
from .v2021_07_01.operations import Operations as OperationClass
437453
else:
438454
raise NotImplementedError("APIVersion {} is not available".format(api_version))
439455
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -450,6 +466,7 @@ def private_endpoint_connections(self):
450466
* 2021-02-01: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.containerservice.v2021_02_01.operations.PrivateEndpointConnectionsOperations>`
451467
* 2021-03-01: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.containerservice.v2021_03_01.operations.PrivateEndpointConnectionsOperations>`
452468
* 2021-05-01: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.containerservice.v2021_05_01.operations.PrivateEndpointConnectionsOperations>`
469+
* 2021-05-01: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.containerservice.v2021_07_01.operations.PrivateEndpointConnectionsOperations>`
453470
"""
454471
api_version = self._get_api_version('private_endpoint_connections')
455472
if api_version == '2020-06-01':
@@ -468,6 +485,8 @@ def private_endpoint_connections(self):
468485
from .v2021_03_01.operations import PrivateEndpointConnectionsOperations as OperationClass
469486
elif api_version == '2021-05-01':
470487
from .v2021_05_01.operations import PrivateEndpointConnectionsOperations as OperationClass
488+
elif api_version == '2021-05-01':
489+
from .v2021_07_01.operations import PrivateEndpointConnectionsOperations as OperationClass
471490
else:
472491
raise NotImplementedError("APIVersion {} is not available".format(api_version))
473492
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -482,6 +501,7 @@ def private_link_resources(self):
482501
* 2021-02-01: :class:`PrivateLinkResourcesOperations<azure.mgmt.containerservice.v2021_02_01.operations.PrivateLinkResourcesOperations>`
483502
* 2021-03-01: :class:`PrivateLinkResourcesOperations<azure.mgmt.containerservice.v2021_03_01.operations.PrivateLinkResourcesOperations>`
484503
* 2021-05-01: :class:`PrivateLinkResourcesOperations<azure.mgmt.containerservice.v2021_05_01.operations.PrivateLinkResourcesOperations>`
504+
* 2021-05-01: :class:`PrivateLinkResourcesOperations<azure.mgmt.containerservice.v2021_07_01.operations.PrivateLinkResourcesOperations>`
485505
"""
486506
api_version = self._get_api_version('private_link_resources')
487507
if api_version == '2020-09-01':
@@ -496,6 +516,8 @@ def private_link_resources(self):
496516
from .v2021_03_01.operations import PrivateLinkResourcesOperations as OperationClass
497517
elif api_version == '2021-05-01':
498518
from .v2021_05_01.operations import PrivateLinkResourcesOperations as OperationClass
519+
elif api_version == '2021-05-01':
520+
from .v2021_07_01.operations import PrivateLinkResourcesOperations as OperationClass
499521
else:
500522
raise NotImplementedError("APIVersion {} is not available".format(api_version))
501523
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -510,6 +532,7 @@ def resolve_private_link_service_id(self):
510532
* 2021-02-01: :class:`ResolvePrivateLinkServiceIdOperations<azure.mgmt.containerservice.v2021_02_01.operations.ResolvePrivateLinkServiceIdOperations>`
511533
* 2021-03-01: :class:`ResolvePrivateLinkServiceIdOperations<azure.mgmt.containerservice.v2021_03_01.operations.ResolvePrivateLinkServiceIdOperations>`
512534
* 2021-05-01: :class:`ResolvePrivateLinkServiceIdOperations<azure.mgmt.containerservice.v2021_05_01.operations.ResolvePrivateLinkServiceIdOperations>`
535+
* 2021-05-01: :class:`ResolvePrivateLinkServiceIdOperations<azure.mgmt.containerservice.v2021_07_01.operations.ResolvePrivateLinkServiceIdOperations>`
513536
"""
514537
api_version = self._get_api_version('resolve_private_link_service_id')
515538
if api_version == '2020-09-01':
@@ -524,6 +547,8 @@ def resolve_private_link_service_id(self):
524547
from .v2021_03_01.operations import ResolvePrivateLinkServiceIdOperations as OperationClass
525548
elif api_version == '2021-05-01':
526549
from .v2021_05_01.operations import ResolvePrivateLinkServiceIdOperations as OperationClass
550+
elif api_version == '2021-05-01':
551+
from .v2021_07_01.operations import ResolvePrivateLinkServiceIdOperations as OperationClass
527552
else:
528553
raise NotImplementedError("APIVersion {} is not available".format(api_version))
529554
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

sdk/containerservice/azure-mgmt-containerservice/azure/mgmt/containerservice/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@
66
# --------------------------------------------------------------------------
77
from .v2017_07_01.models import *
88
from .v2019_04_30.models import *
9-
from .v2021_05_01.models import *
9+
from .v2021_07_01.models import *
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from ._configuration import ContainerServiceClientConfiguration
13+
from ._container_service_client import ContainerServiceClient
14+
__all__ = ['ContainerServiceClient', 'ContainerServiceClientConfiguration']
15+
16+
from .version import VERSION
17+
18+
__version__ = VERSION
19+
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
from msrestazure import AzureConfiguration
12+
13+
from .version import VERSION
14+
15+
16+
class ContainerServiceClientConfiguration(AzureConfiguration):
17+
"""Configuration for ContainerServiceClient
18+
Note that all parameters used to create this instance are saved as instance
19+
attributes.
20+
21+
:param credentials: Credentials needed for the client to connect to Azure.
22+
:type credentials: :mod:`A msrestazure Credentials
23+
object<msrestazure.azure_active_directory>`
24+
:param subscription_id: Subscription credentials which uniquely identify
25+
Microsoft Azure subscription. The subscription ID forms part of the URI
26+
for every service call.
27+
:type subscription_id: str
28+
:param str base_url: Service URL
29+
"""
30+
31+
def __init__(
32+
self, credentials, subscription_id, base_url=None):
33+
34+
if credentials is None:
35+
raise ValueError("Parameter 'credentials' must not be None.")
36+
if subscription_id is None:
37+
raise ValueError("Parameter 'subscription_id' must not be None.")
38+
if not base_url:
39+
base_url = 'https://management.azure.com'
40+
41+
super(ContainerServiceClientConfiguration, self).__init__(base_url)
42+
43+
# Starting Autorest.Python 4.0.64, make connection pool activated by default
44+
self.keep_alive = True
45+
46+
self.add_user_agent('azure-mgmt-containerservice/{}'.format(VERSION))
47+
self.add_user_agent('Azure-SDK-For-Python')
48+
49+
self.credentials = credentials
50+
self.subscription_id = subscription_id
Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.service_client import SDKClient
13+
from msrest import Serializer, Deserializer
14+
15+
from ._configuration import ContainerServiceClientConfiguration
16+
from .operations import Operations
17+
from .operations import ManagedClustersOperations
18+
from .operations import MaintenanceConfigurationsOperations
19+
from .operations import AgentPoolsOperations
20+
from .operations import PrivateEndpointConnectionsOperations
21+
from .operations import PrivateLinkResourcesOperations
22+
from .operations import ResolvePrivateLinkServiceIdOperations
23+
from . import models
24+
25+
26+
class ContainerServiceClient(SDKClient):
27+
"""The Container Service Client.
28+
29+
:ivar config: Configuration for client.
30+
:vartype config: ContainerServiceClientConfiguration
31+
32+
:ivar operations: Operations operations
33+
:vartype operations: azure.mgmt.containerservice.v2021_07_01.operations.Operations
34+
:ivar managed_clusters: ManagedClusters operations
35+
:vartype managed_clusters: azure.mgmt.containerservice.v2021_07_01.operations.ManagedClustersOperations
36+
:ivar maintenance_configurations: MaintenanceConfigurations operations
37+
:vartype maintenance_configurations: azure.mgmt.containerservice.v2021_07_01.operations.MaintenanceConfigurationsOperations
38+
:ivar agent_pools: AgentPools operations
39+
:vartype agent_pools: azure.mgmt.containerservice.v2021_07_01.operations.AgentPoolsOperations
40+
:ivar private_endpoint_connections: PrivateEndpointConnections operations
41+
:vartype private_endpoint_connections: azure.mgmt.containerservice.v2021_07_01.operations.PrivateEndpointConnectionsOperations
42+
:ivar private_link_resources: PrivateLinkResources operations
43+
:vartype private_link_resources: azure.mgmt.containerservice.v2021_07_01.operations.PrivateLinkResourcesOperations
44+
:ivar resolve_private_link_service_id: ResolvePrivateLinkServiceId operations
45+
:vartype resolve_private_link_service_id: azure.mgmt.containerservice.v2021_07_01.operations.ResolvePrivateLinkServiceIdOperations
46+
47+
:param credentials: Credentials needed for the client to connect to Azure.
48+
:type credentials: :mod:`A msrestazure Credentials
49+
object<msrestazure.azure_active_directory>`
50+
:param subscription_id: Subscription credentials which uniquely identify
51+
Microsoft Azure subscription. The subscription ID forms part of the URI
52+
for every service call.
53+
:type subscription_id: str
54+
:param str base_url: Service URL
55+
"""
56+
57+
def __init__(
58+
self, credentials, subscription_id, base_url=None):
59+
60+
self.config = ContainerServiceClientConfiguration(credentials, subscription_id, base_url)
61+
super(ContainerServiceClient, self).__init__(self.config.credentials, self.config)
62+
63+
client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
64+
self.api_version = '2021-05-01'
65+
self._serialize = Serializer(client_models)
66+
self._deserialize = Deserializer(client_models)
67+
68+
self.operations = Operations(
69+
self._client, self.config, self._serialize, self._deserialize)
70+
self.managed_clusters = ManagedClustersOperations(
71+
self._client, self.config, self._serialize, self._deserialize)
72+
self.maintenance_configurations = MaintenanceConfigurationsOperations(
73+
self._client, self.config, self._serialize, self._deserialize)
74+
self.agent_pools = AgentPoolsOperations(
75+
self._client, self.config, self._serialize, self._deserialize)
76+
self.private_endpoint_connections = PrivateEndpointConnectionsOperations(
77+
self._client, self.config, self._serialize, self._deserialize)
78+
self.private_link_resources = PrivateLinkResourcesOperations(
79+
self._client, self.config, self._serialize, self._deserialize)
80+
self.resolve_private_link_service_id = ResolvePrivateLinkServiceIdOperations(
81+
self._client, self.config, self._serialize, self._deserialize)

0 commit comments

Comments
 (0)