Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
6b9fb8c
Generated from c0def97e9fc1e839db7727fd31c2f583f6cf04d6 (#2486)
AutorestCI Apr 27, 2018
f434626
Generated from 8fe96075f82faeec0c0e316e0dd1a1c0ee77e376 (#2501)
AutorestCI May 2, 2018
755e121
[AutoPR compute/resource-manager] added autoOSUpgradePolicy to Upgrad…
AutorestCI May 8, 2018
eee2ad2
Generated from 87e0684ac67bc015bf82c1f1227093265c2e1233 (#2562)
AutorestCI May 17, 2018
85f3a39
Generated from 7014b952af241255afcf4e2b620cfd40737a3ea1 (#2580)
AutorestCI May 21, 2018
7404489
[AutoPR compute/resource-manager] Added the swagger file for the new …
AutorestCI May 23, 2018
6d22b90
Generated from 4abedb1c096796557fdd029401f3d317f99c7f61 (#2664)
AutorestCI May 31, 2018
e54191c
Generated from a2f275e122829ab63c18494dbaae5a1e9ef6e81c (#2673)
AutorestCI Jun 1, 2018
2bcc242
[AutoPR compute/resource-manager] [Compute] Fix List VM Extension API…
AutorestCI Jun 2, 2018
9c49b8d
Rebuild by https://github.com/Azure/azure-sdk-for-python/pull/2487
AutorestCI Jun 4, 2018
f1235da
Generated from 41175e4e605bb5ed0329cdfa91ae14cfbd6a6739 (#2829)
AutorestCI Jun 30, 2018
2ce5c7e
Generated from 0a9ee3a2db06dff212c23f80c8b7bf1eec31613a (#2858)
AutorestCI Jul 2, 2018
946d5dc
Generated from c34f1fdacb2efacd4dccdd69213e83e4800ab76a (#2859)
AutorestCI Jul 2, 2018
15479ef
Generated from d4e9a10c23b602709da6ec04f970c7802ca60af3 (#2886)
AutorestCI Jul 6, 2018
82c4f0b
Rebuild by https://github.com/Azure/azure-sdk-for-python/pull/2487
AutorestCI Jul 6, 2018
c2f5dce
Update version.py
lmazuel Jul 6, 2018
d75f3b0
Generated from 0e3b2e2f19773ecc8bb676f2d40cff4119b2a357 (#2890)
AutorestCI Jul 9, 2018
4c7955b
[AutoPR compute/resource-manager] Update RunCommand operation output …
AutorestCI Jul 10, 2018
595c28a
Generated from ac9f623bcc6d676360abc57b52b6ee8b0341ea18 (#2914)
AutorestCI Jul 11, 2018
1d5ff49
[AutoPR compute/resource-manager] Update VMSS planned maintenance des…
AutorestCI Jul 11, 2018
663e409
Generated from cb39de62c1bac51455eaf7ad3fbe8ac9ec84df58 (#2918)
AutorestCI Jul 13, 2018
8175b81
Generated from b59db77683f3a9c65d0edec17b5f05e458a68897 (#2942)
AutorestCI Jul 18, 2018
2a6625e
[AutoPR compute/resource-manager] RunCommands 2018-06-01 (#2935)
AutorestCI Jul 19, 2018
219480c
Generated from 8f17cd0bc03fad3ed3a5259ec37e9add84ff73a7 (#2965)
AutorestCI Jul 20, 2018
d26c3a1
Fix multi api client
lmazuel Jul 20, 2018
b45ffbe
Update Autorest min version for Compute
lmazuel Jul 20, 2018
b6c3396
Fixing tests for latest Compute
lmazuel Jul 20, 2018
dfcc1a5
Make it stable
lmazuel Jul 20, 2018
1ccf250
ChangeLog
lmazuel Jul 20, 2018
1321efb
Merge branch 'master' into restapi_auto_compute/resource-manager
lmazuel Jul 20, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
[AutoPR compute/resource-manager] Added the swagger file for the new …
…service Gallery. (#2563)

* Generated from b48862551b5e97eb40acb3da63e55522a9db566c

Added the swagger file for the new service Gallery.

* Generated from d2537a58b0496d8860759d47a9c344c19d217995

Gallery Python conf

* Generated from 29d0c5762aad64243a021fac44d65b8610304e4e

Fixed description for 202 response.

* Generated from 29d0c5762aad64243a021fac44d65b8610304e4e

Fixed description for 202 response.

* Generated from b74f3ee0fdca928bf92a7fdd2bcd17994deadca9

Changed the operationId to conform to naming convention.

* Generated from 664c041aeed346e4fdc3a2c8c29c1c59e7505b66

Fixed some typos.

* Generated from e7ab96432e0bfc7c49839ca5d1194ec1be0c23a9

Add default error response. Make provisioningInfo a enum type.

* Generated from c26feda2acff5be97893b6e5db4270e09dbf1c25

Fixed comments according to CR.

* Generated from b757a4ec5fd9e1a35bedefd53fe3d92e111db5eb

Resolved merge conflicts.
  • Loading branch information
AutorestCI committed Jul 6, 2018
commit 74044899c695474a33b001a598630ba1b269e0ae
43 changes: 43 additions & 0 deletions azure-mgmt-compute/azure/mgmt/compute/compute_management_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ def models(cls, api_version=DEFAULT_API_VERSION):
* 2017-09-01: :mod:`v2017_09_01.models<azure.mgmt.compute.v2017_09_01.models>`
* 2017-12-01: :mod:`v2017_12_01.models<azure.mgmt.compute.v2017_12_01.models>`
* 2018-04-01: :mod:`v2018_04_01.models<azure.mgmt.compute.v2018_04_01.models>`
* 2018-06-01: :mod:`v2018_06_01.models<azure.mgmt.compute.v2018_06_01.models>`
"""
if api_version == '2015-06-15':
from .v2015_06_15 import models
Expand All @@ -143,6 +144,9 @@ def models(cls, api_version=DEFAULT_API_VERSION):
elif api_version == '2018-04-01':
from .v2018_04_01 import models
return models
elif api_version == '2018-06-01':
from .v2018_06_01 import models
return models
raise NotImplementedError("APIVersion {} is not available".format(api_version))

@property
Expand Down Expand Up @@ -189,6 +193,45 @@ def disks(self):
raise NotImplementedError("APIVersion {} is not available".format(api_version))
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

@property
def galleries(self):
"""Instance depends on the API version:

* 2018-06-01: :class:`GalleriesOperations<azure.mgmt.compute.v2018_06_01.operations.GalleriesOperations>`
"""
api_version = self._get_api_version('galleries')
if api_version == '2018-06-01':
from .v2018_06_01.operations import GalleriesOperations as OperationClass
else:
raise NotImplementedError("APIVersion {} is not available".format(api_version))
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

@property
def gallery_image_versions(self):
"""Instance depends on the API version:

* 2018-06-01: :class:`GalleryImageVersionsOperations<azure.mgmt.compute.v2018_06_01.operations.GalleryImageVersionsOperations>`
"""
api_version = self._get_api_version('gallery_image_versions')
if api_version == '2018-06-01':
from .v2018_06_01.operations import GalleryImageVersionsOperations as OperationClass
else:
raise NotImplementedError("APIVersion {} is not available".format(api_version))
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

@property
def gallery_images(self):
"""Instance depends on the API version:

* 2018-06-01: :class:`GalleryImagesOperations<azure.mgmt.compute.v2018_06_01.operations.GalleryImagesOperations>`
"""
api_version = self._get_api_version('gallery_images')
if api_version == '2018-06-01':
from .v2018_06_01.operations import GalleryImagesOperations as OperationClass
else:
raise NotImplementedError("APIVersion {} is not available".format(api_version))
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

@property
def images(self):
"""Instance depends on the API version:
Expand Down
18 changes: 18 additions & 0 deletions azure-mgmt-compute/azure/mgmt/compute/v2018_06_01/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .compute_management_client import ComputeManagementClient
from .version import VERSION

__all__ = ['ComputeManagementClient']

__version__ = VERSION

Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.service_client import SDKClient
from msrest import Serializer, Deserializer
from msrestazure import AzureConfiguration
from .version import VERSION
from .operations.galleries_operations import GalleriesOperations
from .operations.gallery_images_operations import GalleryImagesOperations
from .operations.gallery_image_versions_operations import GalleryImageVersionsOperations
from . import models


class ComputeManagementClientConfiguration(AzureConfiguration):
"""Configuration for ComputeManagementClient
Note that all parameters used to create this instance are saved as instance
attributes.

:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param subscription_id: Subscription credentials which uniquely identify
Microsoft Azure subscription. The subscription ID forms part of the URI
for every service call.
:type subscription_id: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, subscription_id, base_url=None):

if credentials is None:
raise ValueError("Parameter 'credentials' must not be None.")
if subscription_id is None:
raise ValueError("Parameter 'subscription_id' must not be None.")
if not base_url:
base_url = 'https://management.azure.com'

super(ComputeManagementClientConfiguration, self).__init__(base_url)

self.add_user_agent('azure-mgmt-compute/{}'.format(VERSION))
self.add_user_agent('Azure-SDK-For-Python')

self.credentials = credentials
self.subscription_id = subscription_id


class ComputeManagementClient(SDKClient):
"""Compute Client

:ivar config: Configuration for client.
:vartype config: ComputeManagementClientConfiguration

:ivar galleries: Galleries operations
:vartype galleries: azure.mgmt.compute.v2018_06_01.operations.GalleriesOperations
:ivar gallery_images: GalleryImages operations
:vartype gallery_images: azure.mgmt.compute.v2018_06_01.operations.GalleryImagesOperations
:ivar gallery_image_versions: GalleryImageVersions operations
:vartype gallery_image_versions: azure.mgmt.compute.v2018_06_01.operations.GalleryImageVersionsOperations

:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param subscription_id: Subscription credentials which uniquely identify
Microsoft Azure subscription. The subscription ID forms part of the URI
for every service call.
:type subscription_id: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, subscription_id, base_url=None):

self.config = ComputeManagementClientConfiguration(credentials, subscription_id, base_url)
super(ComputeManagementClient, self).__init__(self.config.credentials, self.config)

client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
self.api_version = '2018-06-01'
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)

self.galleries = GalleriesOperations(
self._client, self.config, self._serialize, self._deserialize)
self.gallery_images = GalleryImagesOperations(
self._client, self.config, self._serialize, self._deserialize)
self.gallery_image_versions = GalleryImageVersionsOperations(
self._client, self.config, self._serialize, self._deserialize)
108 changes: 108 additions & 0 deletions azure-mgmt-compute/azure/mgmt/compute/v2018_06_01/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

try:
from .gallery_identifier_py3 import GalleryIdentifier
from .gallery_py3 import Gallery
from .gallery_image_identifier_py3 import GalleryImageIdentifier
from .resource_range_py3 import ResourceRange
from .recommended_machine_configuration_py3 import RecommendedMachineConfiguration
from .disallowed_py3 import Disallowed
from .image_purchase_plan_py3 import ImagePurchasePlan
from .gallery_image_py3 import GalleryImage
from .gallery_image_version_publishing_profile_py3 import GalleryImageVersionPublishingProfile
from .gallery_os_disk_image_py3 import GalleryOSDiskImage
from .gallery_data_disk_image_py3 import GalleryDataDiskImage
from .gallery_image_version_storage_profile_py3 import GalleryImageVersionStorageProfile
from .regional_replication_status_py3 import RegionalReplicationStatus
from .replication_status_py3 import ReplicationStatus
from .gallery_image_version_py3 import GalleryImageVersion
from .managed_artifact_py3 import ManagedArtifact
from .gallery_artifact_source_py3 import GalleryArtifactSource
from .gallery_artifact_publishing_profile_base_py3 import GalleryArtifactPublishingProfileBase
from .gallery_disk_image_py3 import GalleryDiskImage
from .api_error_base_py3 import ApiErrorBase
from .inner_error_py3 import InnerError
from .api_error_py3 import ApiError
from .operation_status_response_py3 import OperationStatusResponse
from .resource_py3 import Resource
except (SyntaxError, ImportError):
from .gallery_identifier import GalleryIdentifier
from .gallery import Gallery
from .gallery_image_identifier import GalleryImageIdentifier
from .resource_range import ResourceRange
from .recommended_machine_configuration import RecommendedMachineConfiguration
from .disallowed import Disallowed
from .image_purchase_plan import ImagePurchasePlan
from .gallery_image import GalleryImage
from .gallery_image_version_publishing_profile import GalleryImageVersionPublishingProfile
from .gallery_os_disk_image import GalleryOSDiskImage
from .gallery_data_disk_image import GalleryDataDiskImage
from .gallery_image_version_storage_profile import GalleryImageVersionStorageProfile
from .regional_replication_status import RegionalReplicationStatus
from .replication_status import ReplicationStatus
from .gallery_image_version import GalleryImageVersion
from .managed_artifact import ManagedArtifact
from .gallery_artifact_source import GalleryArtifactSource
from .gallery_artifact_publishing_profile_base import GalleryArtifactPublishingProfileBase
from .gallery_disk_image import GalleryDiskImage
from .api_error_base import ApiErrorBase
from .inner_error import InnerError
from .api_error import ApiError
from .operation_status_response import OperationStatusResponse
from .resource import Resource
from .gallery_paged import GalleryPaged
from .gallery_image_paged import GalleryImagePaged
from .gallery_image_version_paged import GalleryImageVersionPaged
from .compute_management_client_enums import (
OperatingSystemTypes,
OperatingSystemStateTypes,
AggregatedReplicationState,
ReplicationState,
HostCaching,
ReplicationStatusTypes,
)

__all__ = [
'GalleryIdentifier',
'Gallery',
'GalleryImageIdentifier',
'ResourceRange',
'RecommendedMachineConfiguration',
'Disallowed',
'ImagePurchasePlan',
'GalleryImage',
'GalleryImageVersionPublishingProfile',
'GalleryOSDiskImage',
'GalleryDataDiskImage',
'GalleryImageVersionStorageProfile',
'RegionalReplicationStatus',
'ReplicationStatus',
'GalleryImageVersion',
'ManagedArtifact',
'GalleryArtifactSource',
'GalleryArtifactPublishingProfileBase',
'GalleryDiskImage',
'ApiErrorBase',
'InnerError',
'ApiError',
'OperationStatusResponse',
'Resource',
'GalleryPaged',
'GalleryImagePaged',
'GalleryImageVersionPaged',
'OperatingSystemTypes',
'OperatingSystemStateTypes',
'AggregatedReplicationState',
'ReplicationState',
'HostCaching',
'ReplicationStatusTypes',
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class ApiError(Model):
"""Api error.

:param details: The Api error details
:type details: list[~azure.mgmt.compute.v2018_06_01.models.ApiErrorBase]
:param innererror: The Api inner error
:type innererror: ~azure.mgmt.compute.v2018_06_01.models.InnerError
:param code: The error code.
:type code: str
:param target: The target of the particular error.
:type target: str
:param message: The error message.
:type message: str
"""

_attribute_map = {
'details': {'key': 'details', 'type': '[ApiErrorBase]'},
'innererror': {'key': 'innererror', 'type': 'InnerError'},
'code': {'key': 'code', 'type': 'str'},
'target': {'key': 'target', 'type': 'str'},
'message': {'key': 'message', 'type': 'str'},
}

def __init__(self, **kwargs):
super(ApiError, self).__init__(**kwargs)
self.details = kwargs.get('details', None)
self.innererror = kwargs.get('innererror', None)
self.code = kwargs.get('code', None)
self.target = kwargs.get('target', None)
self.message = kwargs.get('message', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class ApiErrorBase(Model):
"""Api error base.

:param code: The error code.
:type code: str
:param target: The target of the particular error.
:type target: str
:param message: The error message.
:type message: str
"""

_attribute_map = {
'code': {'key': 'code', 'type': 'str'},
'target': {'key': 'target', 'type': 'str'},
'message': {'key': 'message', 'type': 'str'},
}

def __init__(self, **kwargs):
super(ApiErrorBase, self).__init__(**kwargs)
self.code = kwargs.get('code', None)
self.target = kwargs.get('target', None)
self.message = kwargs.get('message', None)
Loading