diff --git a/azure-mgmt-recoveryservices/HISTORY.rst b/azure-mgmt-recoveryservices/HISTORY.rst index 73c65ece97ea..d0bf5debb2ca 100644 --- a/azure-mgmt-recoveryservices/HISTORY.rst +++ b/azure-mgmt-recoveryservices/HISTORY.rst @@ -3,6 +3,15 @@ Release History =============== +0.2.0 (2017-10-16) +++++++++++++++++++ + +**Bugfixes** + +* blob_duration is now a str (from iso-8601) +* "service_specification" is renamed "properties.service_specification" +* Fix operations list + 0.1.0 (2017-07-20) ++++++++++++++++++ diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/__init__.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/__init__.py index 006cfb628da4..cc8accc616db 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/__init__.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/__init__.py @@ -30,6 +30,7 @@ from .client_discovery_display import ClientDiscoveryDisplay from .client_discovery_for_log_specification import ClientDiscoveryForLogSpecification from .client_discovery_for_service_specification import ClientDiscoveryForServiceSpecification +from .client_discovery_for_properties import ClientDiscoveryForProperties from .client_discovery_value_for_single_api import ClientDiscoveryValueForSingleApi from .name_info import NameInfo from .vault_usage import VaultUsage @@ -71,6 +72,7 @@ 'ClientDiscoveryDisplay', 'ClientDiscoveryForLogSpecification', 'ClientDiscoveryForServiceSpecification', + 'ClientDiscoveryForProperties', 'ClientDiscoveryValueForSingleApi', 'NameInfo', 'VaultUsage', diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_display.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_display.py index 2f8dc8ee9ff0..dbc271de1f39 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_display.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_display.py @@ -15,26 +15,16 @@ class ClientDiscoveryDisplay(Model): """Localized display information of an operation. - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar provider: Name of the resource provider. - :vartype provider: str - :ivar resource: Type of the resource. - :vartype resource: str - :ivar operation: Name of the operation. - :vartype operation: str - :ivar description: Operation description. - :vartype description: str + :param provider: Name of the provider for display purposes + :type provider: str + :param resource: Name of the resource type for display purposes + :type resource: str + :param operation: Name of the operation for display purposes + :type operation: str + :param description: Description of the operation for display purposes + :type description: str """ - _validation = { - 'provider': {'readonly': True}, - 'resource': {'readonly': True}, - 'operation': {'readonly': True}, - 'description': {'readonly': True}, - } - _attribute_map = { 'provider': {'key': 'Provider', 'type': 'str'}, 'resource': {'key': 'Resource', 'type': 'str'}, @@ -42,8 +32,8 @@ class ClientDiscoveryDisplay(Model): 'description': {'key': 'Description', 'type': 'str'}, } - def __init__(self): - self.provider = None - self.resource = None - self.operation = None - self.description = None + def __init__(self, provider=None, resource=None, operation=None, description=None): + self.provider = provider + self.resource = resource + self.operation = operation + self.description = description diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_log_specification.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_log_specification.py index cf2b9d064d1d..63275818193c 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_log_specification.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_log_specification.py @@ -13,32 +13,23 @@ class ClientDiscoveryForLogSpecification(Model): - """Log specification for the operation. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name: Name of the log. - :vartype name: str - :ivar display_name: Localized display name. - :vartype display_name: str - :ivar blob_duration: Blob duration. - :vartype blob_duration: datetime + """Class to represent shoebox log specification in json client discovery. + + :param name: Name of the log. + :type name: str + :param display_name: Localized display name + :type display_name: str + :param blob_duration: Blobs created in customer storage account per hour + :type blob_duration: str """ - _validation = { - 'name': {'readonly': True}, - 'display_name': {'readonly': True}, - 'blob_duration': {'readonly': True}, - } - _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'display_name': {'key': 'displayName', 'type': 'str'}, - 'blob_duration': {'key': 'blobDuration', 'type': 'iso-8601'}, + 'blob_duration': {'key': 'blobDuration', 'type': 'str'}, } - def __init__(self): - self.name = None - self.display_name = None - self.blob_duration = None + def __init__(self, name=None, display_name=None, blob_duration=None): + self.name = name + self.display_name = display_name + self.blob_duration = blob_duration diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_properties.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_properties.py new file mode 100644 index 000000000000..e692182a882e --- /dev/null +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_properties.py @@ -0,0 +1,29 @@ +# 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 ClientDiscoveryForProperties(Model): + """Class to represent shoebox properties in json client discovery. + + :param service_specification: Operation properties. + :type service_specification: + :class:`ClientDiscoveryForServiceSpecification + ` + """ + + _attribute_map = { + 'service_specification': {'key': 'serviceSpecification', 'type': 'ClientDiscoveryForServiceSpecification'}, + } + + def __init__(self, service_specification=None): + self.service_specification = service_specification diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_service_specification.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_service_specification.py index 4be944407bcd..93e71a534bc4 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_service_specification.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_for_service_specification.py @@ -13,24 +13,17 @@ class ClientDiscoveryForServiceSpecification(Model): - """Operation properties. + """Class to represent shoebox service specification in json client discovery. - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar log_specifications: List of log specifications of this operation. - :vartype log_specifications: list of + :param log_specifications: List of log specifications of this operation. + :type log_specifications: list of :class:`ClientDiscoveryForLogSpecification ` """ - _validation = { - 'log_specifications': {'readonly': True}, - } - _attribute_map = { 'log_specifications': {'key': 'logSpecifications', 'type': '[ClientDiscoveryForLogSpecification]'}, } - def __init__(self): - self.log_specifications = None + def __init__(self, log_specifications=None): + self.log_specifications = log_specifications diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_value_for_single_api.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_value_for_single_api.py index d73522f45044..2b5d28a46042 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_value_for_single_api.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/client_discovery_value_for_single_api.py @@ -15,39 +15,29 @@ class ClientDiscoveryValueForSingleApi(Model): """Available operation details. - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name: Name of the operation. - :vartype name: str - :ivar display: Contains the localized display information for this - particular operation. - :vartype display: :class:`ClientDiscoveryDisplay + :param name: Name of the operation + :type name: str + :param display: Contains the localized display information for this + particular operation + :type display: :class:`ClientDiscoveryDisplay ` - :ivar origin: The intended executor of the operation. - :vartype origin: str - :ivar service_specification: Operation properties. - :vartype service_specification: - :class:`ClientDiscoveryForServiceSpecification - ` + :param origin: The intended executor of the operation;governs the display + of the operation in the RBAC UX and the audit logs UX + :type origin: str + :param properties: Properties + :type properties: :class:`ClientDiscoveryForProperties + ` """ - _validation = { - 'name': {'readonly': True}, - 'display': {'readonly': True}, - 'origin': {'readonly': True}, - 'service_specification': {'readonly': True}, - } - _attribute_map = { 'name': {'key': 'Name', 'type': 'str'}, 'display': {'key': 'Display', 'type': 'ClientDiscoveryDisplay'}, 'origin': {'key': 'Origin', 'type': 'str'}, - 'service_specification': {'key': 'Properties.serviceSpecification', 'type': 'ClientDiscoveryForServiceSpecification'}, + 'properties': {'key': 'Properties', 'type': 'ClientDiscoveryForProperties'}, } - def __init__(self): - self.name = None - self.display = None - self.origin = None - self.service_specification = None + def __init__(self, name=None, display=None, origin=None, properties=None): + self.name = name + self.display = display + self.origin = origin + self.properties = properties diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/operations/operations.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/operations/operations.py index e76ef0ca226a..12561d6cac60 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/operations/operations.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/operations/operations.py @@ -36,12 +36,9 @@ def __init__(self, client, config, serializer, deserializer): self.config = config def list( - self, resource_group_name, custom_headers=None, raw=False, **operation_config): + self, custom_headers=None, raw=False, **operation_config): """Returns the list of available operations. - :param resource_group_name: The name of the resource group where the - recovery services vault is present. - :type resource_group_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -58,12 +55,7 @@ def internal_paging(next_link=None, raw=False): if not next_link: # Construct URL - url = '/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/operations' - path_format_arguments = { - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str') - } - url = self._client.format_url(url, **path_format_arguments) + url = '/providers/Microsoft.RecoveryServices/operations' # Construct parameters query_parameters = {} diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/recovery_services_client.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/recovery_services_client.py index 3654319b4f45..a86ba67d5fe9 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/recovery_services_client.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/recovery_services_client.py @@ -60,7 +60,7 @@ def __init__( class RecoveryServicesClient(object): - """Open API 2.0 Specs for Azure RecoveryServices service + """Recovery Services Client :ivar config: Configuration for client. :vartype config: RecoveryServicesClientConfiguration diff --git a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/version.py b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/version.py index e0ec669828cb..9bd1dfac7ecb 100644 --- a/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/version.py +++ b/azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/version.py @@ -9,5 +9,5 @@ # regenerated. # -------------------------------------------------------------------------- -VERSION = "0.1.0" +VERSION = "0.2.0"