Skip to content

Commit

Permalink
CodeGen from PR 16049 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
2021-09-01-privatepreview and rename folder to match resource provider name Microsoft.ServiceFabric (Azure#16049)

Co-authored-by: Alfredo Santamaria Gomez <alsantam@microsoft.com>
  • Loading branch information
SDKAuto and Alfredo Santamaria Gomez committed Sep 22, 2021
1 parent eca1c81 commit 19dd965
Show file tree
Hide file tree
Showing 31 changed files with 1,138 additions and 257 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
{
"autorest": "3.3.0",
"use": "@autorest/python@5.6.6",
"commit": "1b38cd3ccb2224b0c838fd77c870cd72e2a5eff2",
"autorest": "3.4.5",
"use": [
"@autorest/python@5.8.4",
"@autorest/modelerfour@4.19.2"
],
"commit": "cfd43d7d6369876f9feb6de4d6042690830d4202",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest_command": "autorest specification/servicefabricmanagedclusters/resource-manager/readme.md --multiapi --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk --track2 --use=@autorest/python@5.6.6 --version=3.3.0",
"autorest_command": "autorest specification/servicefabricmanagedclusters/resource-manager/readme.md --multiapi --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk --track2 --use=@autorest/python@5.8.4 --use=@autorest/modelerfour@4.19.2 --version=3.4.5",
"readme": "specification/servicefabricmanagedclusters/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def __init__(

self.credential = credential
self.subscription_id = subscription_id
self.api_version = "2021-05-01"
self.api_version = "2021-07-01-preview"
self.credential_scopes = kwargs.pop('credential_scopes', ['https://management.azure.com/.default'])
kwargs.setdefault('sdk_moniker', 'mgmt-servicefabricmanagedclusters/{}'.format(VERSION))
self._configure(**kwargs)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"chosen_version": "2021-05-01",
"total_api_version_list": ["2021-05-01"],
"chosen_version": "2021-07-01-preview",
"total_api_version_list": ["2021-07-01-preview"],
"client": {
"name": "ServiceFabricManagedClustersManagementClient",
"filename": "_service_fabric_managed_clusters_management_client",
Expand Down Expand Up @@ -105,6 +105,7 @@
"managed_clusters": "ManagedClustersOperations",
"managed_cluster_version": "ManagedClusterVersionOperations",
"operations": "Operations",
"node_types": "NodeTypesOperations"
"node_types": "NodeTypesOperations",
"node_type_skus": "NodeTypeSkusOperations"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
from .operations import ManagedClusterVersionOperations
from .operations import Operations
from .operations import NodeTypesOperations
from .operations import NodeTypeSkusOperations
from . import models


Expand All @@ -49,6 +50,8 @@ class ServiceFabricManagedClustersManagementClient(object):
:vartype operations: service_fabric_managed_clusters_management_client.operations.Operations
:ivar node_types: NodeTypesOperations operations
:vartype node_types: service_fabric_managed_clusters_management_client.operations.NodeTypesOperations
:ivar node_type_skus: NodeTypeSkusOperations operations
:vartype node_type_skus: service_fabric_managed_clusters_management_client.operations.NodeTypeSkusOperations
:param credential: Credential needed for the client to connect to Azure.
:type credential: ~azure.core.credentials.TokenCredential
:param subscription_id: The customer subscription identifier.
Expand Down Expand Up @@ -91,6 +94,8 @@ def __init__(
self._client, self._config, self._serialize, self._deserialize)
self.node_types = NodeTypesOperations(
self._client, self._config, self._serialize, self._deserialize)
self.node_type_skus = NodeTypeSkusOperations(
self._client, self._config, self._serialize, self._deserialize)

def _send_request(self, http_request, **kwargs):
# type: (HttpRequest, Any) -> HttpResponse
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

VERSION = "1.0.0"
VERSION = "0.1.0"
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(

self.credential = credential
self.subscription_id = subscription_id
self.api_version = "2021-05-01"
self.api_version = "2021-07-01-preview"
self.credential_scopes = kwargs.pop('credential_scopes', ['https://management.azure.com/.default'])
kwargs.setdefault('sdk_moniker', 'mgmt-servicefabricmanagedclusters/{}'.format(VERSION))
self._configure(**kwargs)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
from .operations import ManagedClusterVersionOperations
from .operations import Operations
from .operations import NodeTypesOperations
from .operations import NodeTypeSkusOperations
from .. import models


Expand All @@ -47,6 +48,8 @@ class ServiceFabricManagedClustersManagementClient(object):
:vartype operations: service_fabric_managed_clusters_management_client.aio.operations.Operations
:ivar node_types: NodeTypesOperations operations
:vartype node_types: service_fabric_managed_clusters_management_client.aio.operations.NodeTypesOperations
:ivar node_type_skus: NodeTypeSkusOperations operations
:vartype node_type_skus: service_fabric_managed_clusters_management_client.aio.operations.NodeTypeSkusOperations
:param credential: Credential needed for the client to connect to Azure.
:type credential: ~azure.core.credentials_async.AsyncTokenCredential
:param subscription_id: The customer subscription identifier.
Expand Down Expand Up @@ -88,6 +91,8 @@ def __init__(
self._client, self._config, self._serialize, self._deserialize)
self.node_types = NodeTypesOperations(
self._client, self._config, self._serialize, self._deserialize)
self.node_type_skus = NodeTypeSkusOperations(
self._client, self._config, self._serialize, self._deserialize)

async def _send_request(self, http_request: HttpRequest, **kwargs: Any) -> AsyncHttpResponse:
"""Runs the network request through the client's chained policies.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
from ._managed_cluster_version_operations import ManagedClusterVersionOperations
from ._operations import Operations
from ._node_types_operations import NodeTypesOperations
from ._node_type_skus_operations import NodeTypeSkusOperations

__all__ = [
'ApplicationTypesOperations',
Expand All @@ -24,4 +25,5 @@
'ManagedClusterVersionOperations',
'Operations',
'NodeTypesOperations',
'NodeTypeSkusOperations',
]
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ async def get(
cluster_name: str,
application_type_name: str,
version: str,
**kwargs
**kwargs: Any
) -> "_models.ApplicationTypeVersionResource":
"""Gets a Service Fabric managed application type version resource.
Expand All @@ -74,7 +74,7 @@ async def get(
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
accept = "application/json"

# Construct URL
Expand Down Expand Up @@ -120,14 +120,14 @@ async def _create_or_update_initial(
application_type_name: str,
version: str,
parameters: "_models.ApplicationTypeVersionResource",
**kwargs
**kwargs: Any
) -> "_models.ApplicationTypeVersionResource":
cls = kwargs.pop('cls', None) # type: ClsType["_models.ApplicationTypeVersionResource"]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
content_type = kwargs.pop("content_type", "application/json")
accept = "application/json"

Expand Down Expand Up @@ -182,7 +182,7 @@ async def begin_create_or_update(
application_type_name: str,
version: str,
parameters: "_models.ApplicationTypeVersionResource",
**kwargs
**kwargs: Any
) -> AsyncLROPoller["_models.ApplicationTypeVersionResource"]:
"""Creates or updates a Service Fabric managed application type version resource.
Expand All @@ -201,8 +201,8 @@ async def begin_create_or_update(
:type parameters: ~service_fabric_managed_clusters_management_client.models.ApplicationTypeVersionResource
:keyword callable cls: A custom type or function that will be passed the direct response
:keyword str continuation_token: A continuation token to restart a poller from a saved state.
:keyword polling: Pass in True if you'd like the AsyncARMPolling polling method,
False for no polling, or your own initialized polling object for a personal polling strategy.
:keyword polling: By default, your polling method will be AsyncARMPolling.
Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.
:paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
:return: An instance of AsyncLROPoller that returns either ApplicationTypeVersionResource or the result of cls(response)
Expand Down Expand Up @@ -266,7 +266,7 @@ async def update(
application_type_name: str,
version: str,
parameters: "_models.ApplicationTypeVersionUpdateParameters",
**kwargs
**kwargs: Any
) -> "_models.ApplicationTypeVersionResource":
"""Updates the tags of an application type version resource of a given managed cluster.
Expand All @@ -292,7 +292,7 @@ async def update(
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
content_type = kwargs.pop("content_type", "application/json")
accept = "application/json"

Expand Down Expand Up @@ -342,14 +342,14 @@ async def _delete_initial(
cluster_name: str,
application_type_name: str,
version: str,
**kwargs
**kwargs: Any
) -> None:
cls = kwargs.pop('cls', None) # type: ClsType[None]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
accept = "application/json"

# Construct URL
Expand Down Expand Up @@ -391,7 +391,7 @@ async def begin_delete(
cluster_name: str,
application_type_name: str,
version: str,
**kwargs
**kwargs: Any
) -> AsyncLROPoller[None]:
"""Deletes a Service Fabric managed application type version resource.
Expand All @@ -407,8 +407,8 @@ async def begin_delete(
:type version: str
:keyword callable cls: A custom type or function that will be passed the direct response
:keyword str continuation_token: A continuation token to restart a poller from a saved state.
:keyword polling: Pass in True if you'd like the AsyncARMPolling polling method,
False for no polling, or your own initialized polling object for a personal polling strategy.
:keyword polling: By default, your polling method will be AsyncARMPolling.
Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.
:paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
:return: An instance of AsyncLROPoller that returns either None or the result of cls(response)
Expand Down Expand Up @@ -466,7 +466,7 @@ def list_by_application_types(
resource_group_name: str,
cluster_name: str,
application_type_name: str,
**kwargs
**kwargs: Any
) -> AsyncIterable["_models.ApplicationTypeVersionResourceList"]:
"""Gets the list of application type version resources created in the specified Service Fabric managed application type name resource.
Expand All @@ -489,7 +489,7 @@ def list_by_application_types(
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
accept = "application/json"

def prepare_request(next_link=None):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ async def get(
resource_group_name: str,
cluster_name: str,
application_type_name: str,
**kwargs
**kwargs: Any
) -> "_models.ApplicationTypeResource":
"""Gets a Service Fabric managed application type name resource.
Expand All @@ -71,7 +71,7 @@ async def get(
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
accept = "application/json"

# Construct URL
Expand Down Expand Up @@ -115,7 +115,7 @@ async def create_or_update(
cluster_name: str,
application_type_name: str,
parameters: "_models.ApplicationTypeResource",
**kwargs
**kwargs: Any
) -> "_models.ApplicationTypeResource":
"""Creates or updates a Service Fabric managed application type name resource.
Expand All @@ -140,7 +140,7 @@ async def create_or_update(
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
content_type = kwargs.pop("content_type", "application/json")
accept = "application/json"

Expand Down Expand Up @@ -189,7 +189,7 @@ async def update(
cluster_name: str,
application_type_name: str,
parameters: "_models.ApplicationTypeUpdateParameters",
**kwargs
**kwargs: Any
) -> "_models.ApplicationTypeResource":
"""Updates the tags of an application type resource of a given managed cluster.
Expand All @@ -213,7 +213,7 @@ async def update(
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
content_type = kwargs.pop("content_type", "application/json")
accept = "application/json"

Expand Down Expand Up @@ -261,14 +261,14 @@ async def _delete_initial(
resource_group_name: str,
cluster_name: str,
application_type_name: str,
**kwargs
**kwargs: Any
) -> None:
cls = kwargs.pop('cls', None) # type: ClsType[None]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
accept = "application/json"

# Construct URL
Expand Down Expand Up @@ -308,7 +308,7 @@ async def begin_delete(
resource_group_name: str,
cluster_name: str,
application_type_name: str,
**kwargs
**kwargs: Any
) -> AsyncLROPoller[None]:
"""Deletes a Service Fabric managed application type name resource.
Expand All @@ -322,8 +322,8 @@ async def begin_delete(
:type application_type_name: str
:keyword callable cls: A custom type or function that will be passed the direct response
:keyword str continuation_token: A continuation token to restart a poller from a saved state.
:keyword polling: Pass in True if you'd like the AsyncARMPolling polling method,
False for no polling, or your own initialized polling object for a personal polling strategy.
:keyword polling: By default, your polling method will be AsyncARMPolling.
Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.
:paramtype polling: bool or ~azure.core.polling.AsyncPollingMethod
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
:return: An instance of AsyncLROPoller that returns either None or the result of cls(response)
Expand Down Expand Up @@ -378,7 +378,7 @@ def list(
self,
resource_group_name: str,
cluster_name: str,
**kwargs
**kwargs: Any
) -> AsyncIterable["_models.ApplicationTypeResourceList"]:
"""Gets the list of application type name resources created in the specified Service Fabric managed cluster resource.
Expand All @@ -399,7 +399,7 @@ def list(
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
error_map.update(kwargs.pop('error_map', {}))
api_version = "2021-05-01"
api_version = "2021-07-01-preview"
accept = "application/json"

def prepare_request(next_link=None):
Expand Down
Loading

0 comments on commit 19dd965

Please sign in to comment.