Skip to content

Commit

Permalink
[AutoRelease] t2-compute-2022-01-06-94013 (Azure#22364)
Browse files Browse the repository at this point in the history
* CodeGen from PR 17254 in Azure/azure-rest-api-specs
Compute add batch tag package-2021-08-01 (Azure#17254)

* version,CHANGELOG

* test

Co-authored-by: SDKAuto <sdkautomation@microsoft.com>
Co-authored-by: PythonSdkPipelines <PythonSdkPipelines>
Co-authored-by: Yuchao Yan <yuchaoyan@microsoft.com>
  • Loading branch information
3 people authored and rakshith91 committed Apr 10, 2022
1 parent 06db64d commit 3608c87
Show file tree
Hide file tree
Showing 1,156 changed files with 306,244 additions and 331,932 deletions.
19 changes: 19 additions & 0 deletions sdk/compute/azure-mgmt-compute/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,24 @@
# Release History

## 24.0.0 (2022-01-06)

**Features**

- Model AccessUri has a new parameter security_data_access_sas
- Model CreationData has a new parameter security_data_uri
- Model DiskRestorePoint has a new parameter replication_state
- Model DiskRestorePoint has a new parameter source_resource_location
- Model DiskSecurityProfile has a new parameter secure_vm_disk_encryption_set_id
- Model GrantAccessData has a new parameter get_secure_vm_guest_state_sas
- Model PurchasePlan has a new parameter promotion_code
- Model RestorePoint has a new parameter time_created
- Model Snapshot has a new parameter security_profile
- Model SnapshotUpdate has a new parameter supported_capabilities

**Breaking changes**

- Model RestorePoint no longer has parameter provisioning_details

## 23.1.0 (2021-10-12)

**Features**
Expand Down
10 changes: 5 additions & 5 deletions sdk/compute/azure-mgmt-compute/_meta.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"autorest": "3.4.5",
"autorest": "3.7.2",
"use": [
"@autorest/python@5.8.4",
"@autorest/modelerfour@4.19.2"
"@autorest/python@5.12.0",
"@autorest/modelerfour@4.19.3"
],
"commit": "3eaa729b3686f20817145e771a8ab707c739dbbd",
"commit": "ac40996ab146d1360a4783665bb6c0b13f345aec",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest_command": "autorest specification/compute/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",
"autorest_command": "autorest specification/compute/resource-manager/readme.md --multiapi --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk --python3-only --track2 --use=@autorest/python@5.12.0 --use=@autorest/modelerfour@4.19.3 --version=3.7.2",
"readme": "specification/compute/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
from typing import Any, Optional

from azure.core.credentials import TokenCredential
from azure.core.pipeline.transport import HttpRequest, HttpResponse

class _SDKClient(object):
def __init__(self, *args, **kwargs):
Expand Down Expand Up @@ -56,21 +55,55 @@ class ComputeManagementClient(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-07-01'
DEFAULT_API_VERSION = '2021-08-01'
_PROFILE_TAG = "azure.mgmt.compute.ComputeManagementClient"
LATEST_PROFILE = ProfileDefinition({
_PROFILE_TAG: {
None: DEFAULT_API_VERSION,
'availability_sets': '2021-07-01',
'capacity_reservation_groups': '2021-07-01',
'capacity_reservations': '2021-07-01',
'cloud_service_operating_systems': '2021-03-01',
'cloud_service_role_instances': '2021-03-01',
'cloud_service_roles': '2021-03-01',
'cloud_services': '2021-03-01',
'cloud_services_update_domain': '2021-03-01',
'disk_accesses': '2021-04-01',
'disk_encryption_sets': '2021-04-01',
'disk_restore_point': '2021-04-01',
'disks': '2021-04-01',
'snapshots': '2021-04-01',
'community_galleries': '2021-07-01',
'community_gallery_image_versions': '2021-07-01',
'community_gallery_images': '2021-07-01',
'dedicated_host_groups': '2021-07-01',
'dedicated_hosts': '2021-07-01',
'galleries': '2021-07-01',
'gallery_application_versions': '2021-07-01',
'gallery_applications': '2021-07-01',
'gallery_image_versions': '2021-07-01',
'gallery_images': '2021-07-01',
'gallery_sharing_profile': '2021-07-01',
'images': '2021-07-01',
'log_analytics': '2021-07-01',
'operations': '2021-07-01',
'proximity_placement_groups': '2021-07-01',
'resource_skus': '2021-07-01',
'restore_point_collections': '2021-07-01',
'restore_points': '2021-07-01',
'shared_galleries': '2021-07-01',
'shared_gallery_image_versions': '2021-07-01',
'shared_gallery_images': '2021-07-01',
'ssh_public_keys': '2021-07-01',
'usage': '2021-07-01',
'virtual_machine_extension_images': '2021-07-01',
'virtual_machine_extensions': '2021-07-01',
'virtual_machine_images': '2021-07-01',
'virtual_machine_images_edge_zone': '2021-07-01',
'virtual_machine_run_commands': '2021-07-01',
'virtual_machine_scale_set_extensions': '2021-07-01',
'virtual_machine_scale_set_rolling_upgrades': '2021-07-01',
'virtual_machine_scale_set_vm_extensions': '2021-07-01',
'virtual_machine_scale_set_vm_run_commands': '2021-07-01',
'virtual_machine_scale_set_vms': '2021-07-01',
'virtual_machine_scale_sets': '2021-07-01',
'virtual_machine_sizes': '2021-07-01',
'virtual_machines': '2021-07-01',
}},
_PROFILE_TAG + " latest"
)
Expand All @@ -80,12 +113,10 @@ def __init__(
credential, # type: "TokenCredential"
subscription_id, # type: str
api_version=None, # type: Optional[str]
base_url=None, # type: Optional[str]
base_url="https://management.azure.com", # type: str
profile=KnownProfiles.default, # type: KnownProfiles
**kwargs # type: Any
):
if not base_url:
base_url = 'https://management.azure.com'
self._config = ComputeManagementClientConfiguration(credential, subscription_id, **kwargs)
self._client = ARMPipelineClient(base_url=base_url, config=self._config, **kwargs)
super(ComputeManagementClient, self).__init__(
Expand Down Expand Up @@ -125,6 +156,7 @@ def models(cls, api_version=DEFAULT_API_VERSION):
* 2021-03-01: :mod:`v2021_03_01.models<azure.mgmt.compute.v2021_03_01.models>`
* 2021-04-01: :mod:`v2021_04_01.models<azure.mgmt.compute.v2021_04_01.models>`
* 2021-07-01: :mod:`v2021_07_01.models<azure.mgmt.compute.v2021_07_01.models>`
* 2021-08-01: :mod:`v2021_08_01.models<azure.mgmt.compute.v2021_08_01.models>`
"""
if api_version == '2015-06-15':
from .v2015_06_15 import models
Expand Down Expand Up @@ -198,6 +230,9 @@ def models(cls, api_version=DEFAULT_API_VERSION):
elif api_version == '2021-07-01':
from .v2021_07_01 import models
return models
elif api_version == '2021-08-01':
from .v2021_08_01 import models
return models
raise ValueError("API version {} is not available".format(api_version))

@property
Expand Down Expand Up @@ -483,6 +518,7 @@ def disk_accesses(self):
* 2020-09-30: :class:`DiskAccessesOperations<azure.mgmt.compute.v2020_09_30.operations.DiskAccessesOperations>`
* 2020-12-01: :class:`DiskAccessesOperations<azure.mgmt.compute.v2020_12_01.operations.DiskAccessesOperations>`
* 2021-04-01: :class:`DiskAccessesOperations<azure.mgmt.compute.v2021_04_01.operations.DiskAccessesOperations>`
* 2021-08-01: :class:`DiskAccessesOperations<azure.mgmt.compute.v2021_08_01.operations.DiskAccessesOperations>`
"""
api_version = self._get_api_version('disk_accesses')
if api_version == '2020-05-01':
Expand All @@ -495,6 +531,8 @@ def disk_accesses(self):
from .v2020_12_01.operations import DiskAccessesOperations as OperationClass
elif api_version == '2021-04-01':
from .v2021_04_01.operations import DiskAccessesOperations as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import DiskAccessesOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'disk_accesses'".format(api_version))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
Expand All @@ -510,6 +548,7 @@ def disk_encryption_sets(self):
* 2020-09-30: :class:`DiskEncryptionSetsOperations<azure.mgmt.compute.v2020_09_30.operations.DiskEncryptionSetsOperations>`
* 2020-12-01: :class:`DiskEncryptionSetsOperations<azure.mgmt.compute.v2020_12_01.operations.DiskEncryptionSetsOperations>`
* 2021-04-01: :class:`DiskEncryptionSetsOperations<azure.mgmt.compute.v2021_04_01.operations.DiskEncryptionSetsOperations>`
* 2021-08-01: :class:`DiskEncryptionSetsOperations<azure.mgmt.compute.v2021_08_01.operations.DiskEncryptionSetsOperations>`
"""
api_version = self._get_api_version('disk_encryption_sets')
if api_version == '2019-07-01':
Expand All @@ -526,6 +565,8 @@ def disk_encryption_sets(self):
from .v2020_12_01.operations import DiskEncryptionSetsOperations as OperationClass
elif api_version == '2021-04-01':
from .v2021_04_01.operations import DiskEncryptionSetsOperations as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import DiskEncryptionSetsOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'disk_encryption_sets'".format(api_version))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
Expand All @@ -537,6 +578,7 @@ def disk_restore_point(self):
* 2020-09-30: :class:`DiskRestorePointOperations<azure.mgmt.compute.v2020_09_30.operations.DiskRestorePointOperations>`
* 2020-12-01: :class:`DiskRestorePointOperations<azure.mgmt.compute.v2020_12_01.operations.DiskRestorePointOperations>`
* 2021-04-01: :class:`DiskRestorePointOperations<azure.mgmt.compute.v2021_04_01.operations.DiskRestorePointOperations>`
* 2021-08-01: :class:`DiskRestorePointOperations<azure.mgmt.compute.v2021_08_01.operations.DiskRestorePointOperations>`
"""
api_version = self._get_api_version('disk_restore_point')
if api_version == '2020-09-30':
Expand All @@ -545,6 +587,8 @@ def disk_restore_point(self):
from .v2020_12_01.operations import DiskRestorePointOperations as OperationClass
elif api_version == '2021-04-01':
from .v2021_04_01.operations import DiskRestorePointOperations as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import DiskRestorePointOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'disk_restore_point'".format(api_version))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
Expand All @@ -566,6 +610,7 @@ def disks(self):
* 2020-09-30: :class:`DisksOperations<azure.mgmt.compute.v2020_09_30.operations.DisksOperations>`
* 2020-12-01: :class:`DisksOperations<azure.mgmt.compute.v2020_12_01.operations.DisksOperations>`
* 2021-04-01: :class:`DisksOperations<azure.mgmt.compute.v2021_04_01.operations.DisksOperations>`
* 2021-08-01: :class:`DisksOperations<azure.mgmt.compute.v2021_08_01.operations.DisksOperations>`
"""
api_version = self._get_api_version('disks')
if api_version == '2016-04-30-preview':
Expand Down Expand Up @@ -594,6 +639,8 @@ def disks(self):
from .v2020_12_01.operations import DisksOperations as OperationClass
elif api_version == '2021-04-01':
from .v2021_04_01.operations import DisksOperations as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import DisksOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'disks'".format(api_version))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
Expand Down Expand Up @@ -1060,6 +1107,7 @@ def snapshots(self):
* 2020-09-30: :class:`SnapshotsOperations<azure.mgmt.compute.v2020_09_30.operations.SnapshotsOperations>`
* 2020-12-01: :class:`SnapshotsOperations<azure.mgmt.compute.v2020_12_01.operations.SnapshotsOperations>`
* 2021-04-01: :class:`SnapshotsOperations<azure.mgmt.compute.v2021_04_01.operations.SnapshotsOperations>`
* 2021-08-01: :class:`SnapshotsOperations<azure.mgmt.compute.v2021_08_01.operations.SnapshotsOperations>`
"""
api_version = self._get_api_version('snapshots')
if api_version == '2016-04-30-preview':
Expand Down Expand Up @@ -1088,6 +1136,8 @@ def snapshots(self):
from .v2020_12_01.operations import SnapshotsOperations as OperationClass
elif api_version == '2021-04-01':
from .v2021_04_01.operations import SnapshotsOperations as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import SnapshotsOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'snapshots'".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 @@ -12,7 +12,7 @@

from azure.core.configuration import Configuration
from azure.core.pipeline import policies
from azure.mgmt.core.policies import ARMHttpLoggingPolicy
from azure.mgmt.core.policies import ARMChallengeAuthenticationPolicy, ARMHttpLoggingPolicy

from ._version import VERSION

Expand Down Expand Up @@ -68,4 +68,4 @@ def _configure(
self.redirect_policy = kwargs.get('redirect_policy') or policies.RedirectPolicy(**kwargs)
self.authentication_policy = kwargs.get('authentication_policy')
if self.credential and not self.authentication_policy:
self.authentication_policy = policies.BearerTokenCredentialPolicy(self.credential, *self.credential_scopes, **kwargs)
self.authentication_policy = ARMChallengeAuthenticationPolicy(self.credential, *self.credential_scopes, **kwargs)
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
# license information.
# --------------------------------------------------------------------------

VERSION = "23.1.0"
VERSION = "24.0.0"
Loading

0 comments on commit 3608c87

Please sign in to comment.