Skip to content

Commit

Permalink
[AutoRelease] t2-extendedlocation-2021-09-22-24922 (#20782)
Browse files Browse the repository at this point in the history
* CodeGen from PR 15676 in Azure/azure-rest-api-specs
Amalladi/extendedlocation update operationID field (#15676)

* Add blockchain to latest profile

* Add additional types

* Update operationId field in Swagger, update ListOperations Example

* Revert commit

* prettier fix

Co-authored-by: Mark Cowlishaw <markcowl@microsoft.com>
Co-authored-by: Aditi <amalladi@microsoft.com>

* version,CHANGELOG

* Update CHANGELOG.md

* Update CHANGELOG.md

Co-authored-by: SDKAuto <sdkautomation@microsoft.com>
Co-authored-by: Mark Cowlishaw <markcowl@microsoft.com>
Co-authored-by: Aditi <amalladi@microsoft.com>
Co-authored-by: PythonSdkPipelines <PythonSdkPipelines>
Co-authored-by: Jiefeng Chen <51037443+BigCat20196@users.noreply.github.com>
  • Loading branch information
5 people authored Sep 28, 2021
1 parent 03efaee commit d6f5ea9
Show file tree
Hide file tree
Showing 28 changed files with 3,574 additions and 48 deletions.
14 changes: 13 additions & 1 deletion sdk/extendedlocation/azure-mgmt-extendedlocation/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,21 @@
# Release History

## 1.0.0 (2021-09-22)

**Features**
- Adding a new API Version 2021-08-15
- Adding support for Managed Identity [SystemAssigned]
- Model PatchableCustomLocations has a new parameter identity
- Model CustomLocation has a new parameter identity

**Breaking changes**

- Operation CustomLocationsOperations.update has a new signature

## 1.0.0b2 (2021-05-06)

* Remove v2020_07_15_privatepreview

## 1.0.0b1 (2020-03-25)
## 1.0.0b1 (2021-03-25)

* Initial Release
11 changes: 7 additions & 4 deletions sdk/extendedlocation/azure-mgmt-extendedlocation/_meta.json
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": "70b5215249735bc56df6d9fc20a535f24f655117",
"autorest": "3.4.5",
"use": [
"@autorest/python@5.8.4",
"@autorest/modelerfour@4.19.2"
],
"commit": "e687b0f9c1856f7f20e1c0e1aca53b1e342cde3e",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest_command": "autorest specification/extendedlocation/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/extendedlocation/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/extendedlocation/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class CustomLocations(MultiApiClientMixin, _SDKClient):
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
"""

DEFAULT_API_VERSION = '2021-03-15-preview'
DEFAULT_API_VERSION = '2021-08-15'
_PROFILE_TAG = "azure.mgmt.extendedlocation.CustomLocations"
LATEST_PROFILE = ProfileDefinition({
_PROFILE_TAG: {
Expand Down Expand Up @@ -92,21 +92,28 @@ def models(cls, api_version=DEFAULT_API_VERSION):
"""Module depends on the API version:
* 2021-03-15-preview: :mod:`v2021_03_15_preview.models<azure.mgmt.extendedlocation.v2021_03_15_preview.models>`
* 2021-08-15: :mod:`v2021_08_15.models<azure.mgmt.extendedlocation.v2021_08_15.models>`
"""
if api_version == '2021-03-15-preview':
from .v2021_03_15_preview import models
return models
elif api_version == '2021-08-15':
from .v2021_08_15 import models
return models
raise ValueError("API version {} is not available".format(api_version))

@property
def custom_locations(self):
"""Instance depends on the API version:
* 2021-03-15-preview: :class:`CustomLocationsOperations<azure.mgmt.extendedlocation.v2021_03_15_preview.operations.CustomLocationsOperations>`
* 2021-08-15: :class:`CustomLocationsOperations<azure.mgmt.extendedlocation.v2021_08_15.operations.CustomLocationsOperations>`
"""
api_version = self._get_api_version('custom_locations')
if api_version == '2021-03-15-preview':
from .v2021_03_15_preview.operations import CustomLocationsOperations as OperationClass
elif api_version == '2021-08-15':
from .v2021_08_15.operations import CustomLocationsOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'custom_locations'".format(api_version))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
# license information.
# --------------------------------------------------------------------------

VERSION = "1.0.0b2"
VERSION = "1.0.0"
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class CustomLocations(MultiApiClientMixin, _SDKClient):
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
"""

DEFAULT_API_VERSION = '2021-03-15-preview'
DEFAULT_API_VERSION = '2021-08-15'
_PROFILE_TAG = "azure.mgmt.extendedlocation.CustomLocations"
LATEST_PROFILE = ProfileDefinition({
_PROFILE_TAG: {
Expand Down Expand Up @@ -90,21 +90,28 @@ def models(cls, api_version=DEFAULT_API_VERSION):
"""Module depends on the API version:
* 2021-03-15-preview: :mod:`v2021_03_15_preview.models<azure.mgmt.extendedlocation.v2021_03_15_preview.models>`
* 2021-08-15: :mod:`v2021_08_15.models<azure.mgmt.extendedlocation.v2021_08_15.models>`
"""
if api_version == '2021-03-15-preview':
from ..v2021_03_15_preview import models
return models
elif api_version == '2021-08-15':
from ..v2021_08_15 import models
return models
raise ValueError("API version {} is not available".format(api_version))

@property
def custom_locations(self):
"""Instance depends on the API version:
* 2021-03-15-preview: :class:`CustomLocationsOperations<azure.mgmt.extendedlocation.v2021_03_15_preview.aio.operations.CustomLocationsOperations>`
* 2021-08-15: :class:`CustomLocationsOperations<azure.mgmt.extendedlocation.v2021_08_15.aio.operations.CustomLocationsOperations>`
"""
api_version = self._get_api_version('custom_locations')
if api_version == '2021-03-15-preview':
from ..v2021_03_15_preview.aio.operations import CustomLocationsOperations as OperationClass
elif api_version == '2021-08-15':
from ..v2021_08_15.aio.operations import CustomLocationsOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'custom_locations'".format(api_version))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
# Licensed under the MIT License. See License.txt in the project root for
# license information.
# --------------------------------------------------------------------------
from .v2021_03_15_preview.models import *
from .v2021_08_15.models import *
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.0b2"
VERSION = "1.0.0"
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(self, client, config, serializer, deserializer) -> None:

def list_operations(
self,
**kwargs
**kwargs: Any
) -> AsyncIterable["_models.CustomLocationOperationsList"]:
"""Lists all available Custom Locations operations.
Expand Down Expand Up @@ -108,7 +108,7 @@ async def get_next(next_link=None):

def list_by_subscription(
self,
**kwargs
**kwargs: Any
) -> AsyncIterable["_models.CustomLocationListResult"]:
"""Gets a list of Custom Locations in a subscription.
Expand Down Expand Up @@ -179,7 +179,7 @@ async def get_next(next_link=None):
def list_by_resource_group(
self,
resource_group_name: str,
**kwargs
**kwargs: Any
) -> AsyncIterable["_models.CustomLocationListResult"]:
"""Gets a list of Custom Locations in the specified subscription and resource group.
Expand Down Expand Up @@ -211,7 +211,7 @@ def prepare_request(next_link=None):
url = self.list_by_resource_group.metadata['url'] # type: ignore
path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
}
url = self._client.format_url(url, **path_format_arguments)
# Construct parameters
Expand Down Expand Up @@ -254,7 +254,7 @@ async def get(
self,
resource_group_name: str,
resource_name: str,
**kwargs
**kwargs: Any
) -> "_models.CustomLocation":
"""Gets a Custom Location.
Expand All @@ -281,7 +281,7 @@ async def get(
url = self.get.metadata['url'] # type: ignore
path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
'resourceName': self._serialize.url("resource_name", resource_name, 'str', max_length=63, min_length=1, pattern=r'^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'),
}
url = self._client.format_url(url, **path_format_arguments)
Expand Down Expand Up @@ -316,7 +316,7 @@ async def _create_or_update_initial(
resource_group_name: str,
resource_name: str,
parameters: "_models.CustomLocation",
**kwargs
**kwargs: Any
) -> "_models.CustomLocation":
cls = kwargs.pop('cls', None) # type: ClsType["_models.CustomLocation"]
error_map = {
Expand All @@ -331,7 +331,7 @@ async def _create_or_update_initial(
url = self._create_or_update_initial.metadata['url'] # type: ignore
path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
'resourceName': self._serialize.url("resource_name", resource_name, 'str', max_length=63, min_length=1, pattern=r'^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'),
}
url = self._client.format_url(url, **path_format_arguments)
Expand Down Expand Up @@ -374,7 +374,7 @@ async def begin_create_or_update(
resource_group_name: str,
resource_name: str,
parameters: "_models.CustomLocation",
**kwargs
**kwargs: Any
) -> AsyncLROPoller["_models.CustomLocation"]:
"""Creates or updates a Custom Location.
Expand All @@ -388,8 +388,8 @@ async def begin_create_or_update(
:type parameters: ~azure.mgmt.extendedlocation.v2021_03_15_preview.models.CustomLocation
: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 CustomLocation or the result of cls(response)
Expand Down Expand Up @@ -424,7 +424,7 @@ def get_long_running_output(pipeline_response):

path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
'resourceName': self._serialize.url("resource_name", resource_name, 'str', max_length=63, min_length=1, pattern=r'^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'),
}

Expand All @@ -446,7 +446,7 @@ async def _delete_initial(
self,
resource_group_name: str,
resource_name: str,
**kwargs
**kwargs: Any
) -> None:
cls = kwargs.pop('cls', None) # type: ClsType[None]
error_map = {
Expand All @@ -460,7 +460,7 @@ async def _delete_initial(
url = self._delete_initial.metadata['url'] # type: ignore
path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
'resourceName': self._serialize.url("resource_name", resource_name, 'str', max_length=63, min_length=1, pattern=r'^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'),
}
url = self._client.format_url(url, **path_format_arguments)
Expand Down Expand Up @@ -491,7 +491,7 @@ async def begin_delete(
self,
resource_group_name: str,
resource_name: str,
**kwargs
**kwargs: Any
) -> AsyncLROPoller[None]:
"""Deletes a Custom Location.
Expand All @@ -504,8 +504,8 @@ async def begin_delete(
:type resource_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 @@ -536,7 +536,7 @@ def get_long_running_output(pipeline_response):

path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
'resourceName': self._serialize.url("resource_name", resource_name, 'str', max_length=63, min_length=1, pattern=r'^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'),
}

Expand Down Expand Up @@ -566,7 +566,7 @@ async def update(
host_type: Optional[Union[str, "_models.HostType"]] = None,
namespace: Optional[str] = None,
provisioning_state: Optional[str] = None,
**kwargs
**kwargs: Any
) -> "_models.CustomLocation":
"""Updates a Custom Location.
Expand Down Expand Up @@ -616,7 +616,7 @@ async def update(
url = self.update.metadata['url'] # type: ignore
path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
'resourceName': self._serialize.url("resource_name", resource_name, 'str', max_length=63, min_length=1, pattern=r'^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'),
}
url = self._client.format_url(url, **path_format_arguments)
Expand Down Expand Up @@ -654,7 +654,7 @@ def list_enabled_resource_types(
self,
resource_group_name: str,
resource_name: str,
**kwargs
**kwargs: Any
) -> AsyncIterable["_models.EnabledResourceTypesListResult"]:
"""Gets the list of Enabled Resource Types.
Expand Down Expand Up @@ -687,7 +687,7 @@ def prepare_request(next_link=None):
url = self.list_enabled_resource_types.metadata['url'] # type: ignore
path_format_arguments = {
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1, pattern=r'^[-\w\._\(\)]+$'),
'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str', max_length=90, min_length=1),
'resourceName': self._serialize.url("resource_name", resource_name, 'str', max_length=63, min_length=1, pattern=r'^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'),
}
url = self._client.format_url(url, **path_format_arguments)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,7 @@ class ErrorAdditionalInfo(msrest.serialization.Model):
:ivar type: The additional info type.
:vartype type: str
:ivar info: The additional info.
:vartype info: str
:vartype info: any
"""

_validation = {
Expand All @@ -473,7 +473,7 @@ class ErrorAdditionalInfo(msrest.serialization.Model):

_attribute_map = {
'type': {'key': 'type', 'type': 'str'},
'info': {'key': 'info', 'type': 'str'},
'info': {'key': 'info', 'type': 'object'},
}

def __init__(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ class ErrorAdditionalInfo(msrest.serialization.Model):
:ivar type: The additional info type.
:vartype type: str
:ivar info: The additional info.
:vartype info: str
:vartype info: any
"""

_validation = {
Expand All @@ -505,7 +505,7 @@ class ErrorAdditionalInfo(msrest.serialization.Model):

_attribute_map = {
'type': {'key': 'type', 'type': 'str'},
'info': {'key': 'info', 'type': 'str'},
'info': {'key': 'info', 'type': 'object'},
}

def __init__(
Expand Down
Loading

0 comments on commit d6f5ea9

Please sign in to comment.