Skip to content

Commit 7000983

Browse files
msyycSDK Automation
andauthored
[T1]compute (Azure#14551)
* Generated from 266f449de55e060215e4637e14e71c68ae65c146 * version,CHANGELOG,live test Co-authored-by: SDK Automation <[email protected]>
1 parent d643def commit 7000983

File tree

49 files changed

+25408
-17087
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+25408
-17087
lines changed

sdk/compute/azure-mgmt-compute/CHANGELOG.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,24 @@
11
# Release History
22

3+
## 14.0.0 (2020-10-15)
4+
5+
**Features**
6+
7+
- Model GalleryImageUpdate has a new parameter features
8+
- Model GalleryArtifactVersionSource has a new parameter uri
9+
- Model GalleryUpdate has a new parameter sharing_profile
10+
- Model GalleryImage has a new parameter features
11+
- Model Gallery has a new parameter sharing_profile
12+
- Added operation group GallerySharingProfileOperations
13+
- Added operation group SharedGalleryImageVersionsOperations
14+
- Added operation group SharedGalleryImagesOperations
15+
- Added operation group SharedGalleriesOperations
16+
17+
**Breaking changes**
18+
19+
- Operation GalleriesOperations.get has a new signature
20+
- Operation VirtualMachinesOperations.delete has a new signature
21+
322
## 13.1.1 (2020-09-22)
423

524
**Bugfixes**

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/_compute_management_client.py

Lines changed: 76 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,24 +46,23 @@ class ComputeManagementClient(MultiApiClientMixin, SDKClient):
4646
:type profile: azure.profiles.KnownProfiles
4747
"""
4848

49-
DEFAULT_API_VERSION = '2020-06-30'
49+
DEFAULT_API_VERSION = '2020-09-30'
5050
_PROFILE_TAG = "azure.mgmt.compute.ComputeManagementClient"
5151
LATEST_PROFILE = ProfileDefinition({
5252
_PROFILE_TAG: {
5353
None: DEFAULT_API_VERSION,
5454
'availability_sets': '2020-06-01',
5555
'dedicated_host_groups': '2020-06-01',
5656
'dedicated_hosts': '2020-06-01',
57-
'galleries': '2019-12-01',
58-
'gallery_application_versions': '2019-12-01',
59-
'gallery_applications': '2019-12-01',
60-
'gallery_image_versions': '2019-12-01',
61-
'gallery_images': '2019-12-01',
57+
'disk_accesses': '2020-06-30',
58+
'disk_encryption_sets': '2020-06-30',
59+
'disks': '2020-06-30',
6260
'images': '2020-06-01',
6361
'log_analytics': '2020-06-01',
6462
'operations': '2020-06-01',
6563
'proximity_placement_groups': '2020-06-01',
6664
'resource_skus': '2019-04-01',
65+
'snapshots': '2020-06-30',
6766
'ssh_public_keys': '2020-06-01',
6867
'usage': '2020-06-01',
6968
'virtual_machine_extension_images': '2020-06-01',
@@ -116,6 +115,7 @@ def models(cls, api_version=DEFAULT_API_VERSION):
116115
* 2020-05-01: :mod:`v2020_05_01.models<azure.mgmt.compute.v2020_05_01.models>`
117116
* 2020-06-01: :mod:`v2020_06_01.models<azure.mgmt.compute.v2020_06_01.models>`
118117
* 2020-06-30: :mod:`v2020_06_30.models<azure.mgmt.compute.v2020_06_30.models>`
118+
* 2020-09-30: :mod:`v2020_09_30.models<azure.mgmt.compute.v2020_09_30.models>`
119119
"""
120120
if api_version == '2015-06-15':
121121
from .v2015_06_15 import models
@@ -171,6 +171,9 @@ def models(cls, api_version=DEFAULT_API_VERSION):
171171
elif api_version == '2020-06-30':
172172
from .v2020_06_30 import models
173173
return models
174+
elif api_version == '2020-09-30':
175+
from .v2020_09_30 import models
176+
return models
174177
raise NotImplementedError("APIVersion {} is not available".format(api_version))
175178

176179
@property
@@ -349,6 +352,7 @@ def galleries(self):
349352
* 2019-03-01: :class:`GalleriesOperations<azure.mgmt.compute.v2019_03_01.operations.GalleriesOperations>`
350353
* 2019-07-01: :class:`GalleriesOperations<azure.mgmt.compute.v2019_07_01.operations.GalleriesOperations>`
351354
* 2019-12-01: :class:`GalleriesOperations<azure.mgmt.compute.v2019_12_01.operations.GalleriesOperations>`
355+
* 2020-09-30: :class:`GalleriesOperations<azure.mgmt.compute.v2020_09_30.operations.GalleriesOperations>`
352356
"""
353357
api_version = self._get_api_version('galleries')
354358
if api_version == '2018-06-01':
@@ -359,6 +363,8 @@ def galleries(self):
359363
from .v2019_07_01.operations import GalleriesOperations as OperationClass
360364
elif api_version == '2019-12-01':
361365
from .v2019_12_01.operations import GalleriesOperations as OperationClass
366+
elif api_version == '2020-09-30':
367+
from .v2020_09_30.operations import GalleriesOperations as OperationClass
362368
else:
363369
raise NotImplementedError("APIVersion {} is not available".format(api_version))
364370
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -370,6 +376,7 @@ def gallery_application_versions(self):
370376
* 2019-03-01: :class:`GalleryApplicationVersionsOperations<azure.mgmt.compute.v2019_03_01.operations.GalleryApplicationVersionsOperations>`
371377
* 2019-07-01: :class:`GalleryApplicationVersionsOperations<azure.mgmt.compute.v2019_07_01.operations.GalleryApplicationVersionsOperations>`
372378
* 2019-12-01: :class:`GalleryApplicationVersionsOperations<azure.mgmt.compute.v2019_12_01.operations.GalleryApplicationVersionsOperations>`
379+
* 2020-09-30: :class:`GalleryApplicationVersionsOperations<azure.mgmt.compute.v2020_09_30.operations.GalleryApplicationVersionsOperations>`
373380
"""
374381
api_version = self._get_api_version('gallery_application_versions')
375382
if api_version == '2019-03-01':
@@ -378,6 +385,8 @@ def gallery_application_versions(self):
378385
from .v2019_07_01.operations import GalleryApplicationVersionsOperations as OperationClass
379386
elif api_version == '2019-12-01':
380387
from .v2019_12_01.operations import GalleryApplicationVersionsOperations as OperationClass
388+
elif api_version == '2020-09-30':
389+
from .v2020_09_30.operations import GalleryApplicationVersionsOperations as OperationClass
381390
else:
382391
raise NotImplementedError("APIVersion {} is not available".format(api_version))
383392
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -389,6 +398,7 @@ def gallery_applications(self):
389398
* 2019-03-01: :class:`GalleryApplicationsOperations<azure.mgmt.compute.v2019_03_01.operations.GalleryApplicationsOperations>`
390399
* 2019-07-01: :class:`GalleryApplicationsOperations<azure.mgmt.compute.v2019_07_01.operations.GalleryApplicationsOperations>`
391400
* 2019-12-01: :class:`GalleryApplicationsOperations<azure.mgmt.compute.v2019_12_01.operations.GalleryApplicationsOperations>`
401+
* 2020-09-30: :class:`GalleryApplicationsOperations<azure.mgmt.compute.v2020_09_30.operations.GalleryApplicationsOperations>`
392402
"""
393403
api_version = self._get_api_version('gallery_applications')
394404
if api_version == '2019-03-01':
@@ -397,6 +407,8 @@ def gallery_applications(self):
397407
from .v2019_07_01.operations import GalleryApplicationsOperations as OperationClass
398408
elif api_version == '2019-12-01':
399409
from .v2019_12_01.operations import GalleryApplicationsOperations as OperationClass
410+
elif api_version == '2020-09-30':
411+
from .v2020_09_30.operations import GalleryApplicationsOperations as OperationClass
400412
else:
401413
raise NotImplementedError("APIVersion {} is not available".format(api_version))
402414
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -409,6 +421,7 @@ def gallery_image_versions(self):
409421
* 2019-03-01: :class:`GalleryImageVersionsOperations<azure.mgmt.compute.v2019_03_01.operations.GalleryImageVersionsOperations>`
410422
* 2019-07-01: :class:`GalleryImageVersionsOperations<azure.mgmt.compute.v2019_07_01.operations.GalleryImageVersionsOperations>`
411423
* 2019-12-01: :class:`GalleryImageVersionsOperations<azure.mgmt.compute.v2019_12_01.operations.GalleryImageVersionsOperations>`
424+
* 2020-09-30: :class:`GalleryImageVersionsOperations<azure.mgmt.compute.v2020_09_30.operations.GalleryImageVersionsOperations>`
412425
"""
413426
api_version = self._get_api_version('gallery_image_versions')
414427
if api_version == '2018-06-01':
@@ -419,6 +432,8 @@ def gallery_image_versions(self):
419432
from .v2019_07_01.operations import GalleryImageVersionsOperations as OperationClass
420433
elif api_version == '2019-12-01':
421434
from .v2019_12_01.operations import GalleryImageVersionsOperations as OperationClass
435+
elif api_version == '2020-09-30':
436+
from .v2020_09_30.operations import GalleryImageVersionsOperations as OperationClass
422437
else:
423438
raise NotImplementedError("APIVersion {} is not available".format(api_version))
424439
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -431,6 +446,7 @@ def gallery_images(self):
431446
* 2019-03-01: :class:`GalleryImagesOperations<azure.mgmt.compute.v2019_03_01.operations.GalleryImagesOperations>`
432447
* 2019-07-01: :class:`GalleryImagesOperations<azure.mgmt.compute.v2019_07_01.operations.GalleryImagesOperations>`
433448
* 2019-12-01: :class:`GalleryImagesOperations<azure.mgmt.compute.v2019_12_01.operations.GalleryImagesOperations>`
449+
* 2020-09-30: :class:`GalleryImagesOperations<azure.mgmt.compute.v2020_09_30.operations.GalleryImagesOperations>`
434450
"""
435451
api_version = self._get_api_version('gallery_images')
436452
if api_version == '2018-06-01':
@@ -441,6 +457,21 @@ def gallery_images(self):
441457
from .v2019_07_01.operations import GalleryImagesOperations as OperationClass
442458
elif api_version == '2019-12-01':
443459
from .v2019_12_01.operations import GalleryImagesOperations as OperationClass
460+
elif api_version == '2020-09-30':
461+
from .v2020_09_30.operations import GalleryImagesOperations as OperationClass
462+
else:
463+
raise NotImplementedError("APIVersion {} is not available".format(api_version))
464+
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
465+
466+
@property
467+
def gallery_sharing_profile(self):
468+
"""Instance depends on the API version:
469+
470+
* 2020-09-30: :class:`GallerySharingProfileOperations<azure.mgmt.compute.v2020_09_30.operations.GallerySharingProfileOperations>`
471+
"""
472+
api_version = self._get_api_version('gallery_sharing_profile')
473+
if api_version == '2020-09-30':
474+
from .v2020_09_30.operations import GallerySharingProfileOperations as OperationClass
444475
else:
445476
raise NotImplementedError("APIVersion {} is not available".format(api_version))
446477
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
@@ -603,6 +634,45 @@ def resource_skus(self):
603634
raise NotImplementedError("APIVersion {} is not available".format(api_version))
604635
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
605636

637+
@property
638+
def shared_galleries(self):
639+
"""Instance depends on the API version:
640+
641+
* 2020-09-30: :class:`SharedGalleriesOperations<azure.mgmt.compute.v2020_09_30.operations.SharedGalleriesOperations>`
642+
"""
643+
api_version = self._get_api_version('shared_galleries')
644+
if api_version == '2020-09-30':
645+
from .v2020_09_30.operations import SharedGalleriesOperations as OperationClass
646+
else:
647+
raise NotImplementedError("APIVersion {} is not available".format(api_version))
648+
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
649+
650+
@property
651+
def shared_gallery_image_versions(self):
652+
"""Instance depends on the API version:
653+
654+
* 2020-09-30: :class:`SharedGalleryImageVersionsOperations<azure.mgmt.compute.v2020_09_30.operations.SharedGalleryImageVersionsOperations>`
655+
"""
656+
api_version = self._get_api_version('shared_gallery_image_versions')
657+
if api_version == '2020-09-30':
658+
from .v2020_09_30.operations import SharedGalleryImageVersionsOperations as OperationClass
659+
else:
660+
raise NotImplementedError("APIVersion {} is not available".format(api_version))
661+
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
662+
663+
@property
664+
def shared_gallery_images(self):
665+
"""Instance depends on the API version:
666+
667+
* 2020-09-30: :class:`SharedGalleryImagesOperations<azure.mgmt.compute.v2020_09_30.operations.SharedGalleryImagesOperations>`
668+
"""
669+
api_version = self._get_api_version('shared_gallery_images')
670+
if api_version == '2020-09-30':
671+
from .v2020_09_30.operations import SharedGalleryImagesOperations as OperationClass
672+
else:
673+
raise NotImplementedError("APIVersion {} is not available".format(api_version))
674+
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
675+
606676
@property
607677
def snapshots(self):
608678
"""Instance depends on the API version:

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@
55
# license information.
66
# --------------------------------------------------------------------------
77
from .v2019_04_01.models import *
8-
from .v2019_12_01.models import *
98
from .v2020_06_01.models import *
109
from .v2020_06_30.models import *
10+
from .v2020_09_30.models import *

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2019_03_01/operations/_virtual_machine_scale_sets_operations.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1774,7 +1774,7 @@ def force_recovery_service_fabric_platform_update_domain_walk(
17741774

17751775
def convert_to_single_placement_group(
17761776
self, resource_group_name, vm_scale_set_name, active_placement_group_id=None, custom_headers=None, raw=False, **operation_config):
1777-
"""Converts SinglePlacementGroup property to false for a existing virtual
1777+
"""Converts SinglePlacementGroup property to true for a existing virtual
17781778
machine scale set.
17791779
17801780
:param resource_group_name: The name of the resource group.

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2019_07_01/operations/_virtual_machine_scale_sets_operations.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1774,7 +1774,7 @@ def force_recovery_service_fabric_platform_update_domain_walk(
17741774

17751775
def convert_to_single_placement_group(
17761776
self, resource_group_name, vm_scale_set_name, active_placement_group_id=None, custom_headers=None, raw=False, **operation_config):
1777-
"""Converts SinglePlacementGroup property to false for a existing virtual
1777+
"""Converts SinglePlacementGroup property to true for a existing virtual
17781778
machine scale set.
17791779
17801780
:param resource_group_name: The name of the resource group.

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2019_12_01/operations/_virtual_machine_scale_sets_operations.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1774,7 +1774,7 @@ def force_recovery_service_fabric_platform_update_domain_walk(
17741774

17751775
def convert_to_single_placement_group(
17761776
self, resource_group_name, vm_scale_set_name, active_placement_group_id=None, custom_headers=None, raw=False, **operation_config):
1777-
"""Converts SinglePlacementGroup property to false for a existing virtual
1777+
"""Converts SinglePlacementGroup property to true for a existing virtual
17781778
machine scale set.
17791779
17801780
:param resource_group_name: The name of the resource group.

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2020_06_01/operations/_virtual_machines_operations.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -427,7 +427,7 @@ def get_long_running_output(response):
427427

428428

429429
def _delete_initial(
430-
self, resource_group_name, vm_name, custom_headers=None, raw=False, **operation_config):
430+
self, resource_group_name, vm_name, force_deletion=None, custom_headers=None, raw=False, **operation_config):
431431
# Construct URL
432432
url = self.delete.metadata['url']
433433
path_format_arguments = {
@@ -439,6 +439,8 @@ def _delete_initial(
439439

440440
# Construct parameters
441441
query_parameters = {}
442+
if force_deletion is not None:
443+
query_parameters['forceDeletion'] = self._serialize.query("force_deletion", force_deletion, 'bool')
442444
query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str')
443445

444446
# Construct headers
@@ -464,13 +466,16 @@ def _delete_initial(
464466
return client_raw_response
465467

466468
def delete(
467-
self, resource_group_name, vm_name, custom_headers=None, raw=False, polling=True, **operation_config):
469+
self, resource_group_name, vm_name, force_deletion=None, custom_headers=None, raw=False, polling=True, **operation_config):
468470
"""The operation to delete a virtual machine.
469471
470472
:param resource_group_name: The name of the resource group.
471473
:type resource_group_name: str
472474
:param vm_name: The name of the virtual machine.
473475
:type vm_name: str
476+
:param force_deletion: Optional parameter to force delete virtual
477+
machines.
478+
:type force_deletion: bool
474479
:param dict custom_headers: headers that will be added to the request
475480
:param bool raw: The poller return type is ClientRawResponse, the
476481
direct response alongside the deserialized response
@@ -485,6 +490,7 @@ def delete(
485490
raw_result = self._delete_initial(
486491
resource_group_name=resource_group_name,
487492
vm_name=vm_name,
493+
force_deletion=force_deletion,
488494
custom_headers=custom_headers,
489495
raw=True,
490496
**operation_config
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 ComputeManagementClientConfiguration
13+
from ._compute_management_client import ComputeManagementClient
14+
__all__ = ['ComputeManagementClient', 'ComputeManagementClientConfiguration']
15+
16+
from .version import VERSION
17+
18+
__version__ = VERSION
19+

0 commit comments

Comments
 (0)