diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/__init__.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/__init__.py index 58562494e087..873f6b045f42 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/__init__.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/__init__.py @@ -21,6 +21,8 @@ from .update_storage_account_parameters import UpdateStorageAccountParameters from .compute_policy_create_or_update_parameters import ComputePolicyCreateOrUpdateParameters from .data_lake_analytics_account_update_parameters import DataLakeAnalyticsAccountUpdateParameters +from .data_lake_analytics_account_properties_basic import DataLakeAnalyticsAccountPropertiesBasic +from .data_lake_analytics_account_basic import DataLakeAnalyticsAccountBasic from .data_lake_analytics_account import DataLakeAnalyticsAccount from .update_firewall_rule_parameters import UpdateFirewallRuleParameters from .resource import Resource @@ -32,14 +34,14 @@ from .sas_token_info_paged import SasTokenInfoPaged from .storage_account_info_paged import StorageAccountInfoPaged from .data_lake_store_account_info_paged import DataLakeStoreAccountInfoPaged -from .data_lake_analytics_account_paged import DataLakeAnalyticsAccountPaged +from .data_lake_analytics_account_basic_paged import DataLakeAnalyticsAccountBasicPaged from .data_lake_analytics_account_management_client_enums import ( - DataLakeAnalyticsAccountStatus, - DataLakeAnalyticsAccountState, TierType, FirewallState, FirewallAllowAzureIpsState, AADObjectType, + DataLakeAnalyticsAccountStatus, + DataLakeAnalyticsAccountState, ) __all__ = [ @@ -55,6 +57,8 @@ 'UpdateStorageAccountParameters', 'ComputePolicyCreateOrUpdateParameters', 'DataLakeAnalyticsAccountUpdateParameters', + 'DataLakeAnalyticsAccountPropertiesBasic', + 'DataLakeAnalyticsAccountBasic', 'DataLakeAnalyticsAccount', 'UpdateFirewallRuleParameters', 'Resource', @@ -66,11 +70,11 @@ 'SasTokenInfoPaged', 'StorageAccountInfoPaged', 'DataLakeStoreAccountInfoPaged', - 'DataLakeAnalyticsAccountPaged', - 'DataLakeAnalyticsAccountStatus', - 'DataLakeAnalyticsAccountState', + 'DataLakeAnalyticsAccountBasicPaged', 'TierType', 'FirewallState', 'FirewallAllowAzureIpsState', 'AADObjectType', + 'DataLakeAnalyticsAccountStatus', + 'DataLakeAnalyticsAccountState', ] diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/compute_policy_paged.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/compute_policy_paged.py index b78296478fff..3cd24ed75e18 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/compute_policy_paged.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/compute_policy_paged.py @@ -14,7 +14,7 @@ class ComputePolicyPaged(Paged): """ - A paging container for iterating over a list of ComputePolicy object + A paging container for iterating over a list of :class:`ComputePolicy ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account.py index af895db94288..28708bcd73a6 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account.py @@ -39,6 +39,15 @@ class DataLakeAnalyticsAccount(Resource): include: 'Active', 'Suspended' :vartype state: str or :class:`DataLakeAnalyticsAccountState ` + :ivar creation_time: the account creation time. + :vartype creation_time: datetime + :ivar last_modified_time: the account last modified time. + :vartype last_modified_time: datetime + :ivar endpoint: the full CName endpoint for this account. + :vartype endpoint: str + :ivar account_id: The unique identifier associated with this Data Lake + Analytics account. + :vartype account_id: str :param default_data_lake_store_account: the default data lake storage account associated with this Data Lake Analytics account. :type default_data_lake_store_account: str @@ -67,12 +76,6 @@ class DataLakeAnalyticsAccount(Resource): associated with this account. :type storage_accounts: list of :class:`StorageAccountInfo ` - :ivar creation_time: the account creation time. - :vartype creation_time: datetime - :ivar last_modified_time: the account last modified time. - :vartype last_modified_time: datetime - :ivar endpoint: the full CName endpoint for this account. - :vartype endpoint: str :param new_tier: the commitment tier for the next month. Possible values include: 'Consumption', 'Commitment_100AUHours', 'Commitment_500AUHours', 'Commitment_1000AUHours', 'Commitment_5000AUHours', @@ -123,6 +126,10 @@ class DataLakeAnalyticsAccount(Resource): 'location': {'required': True}, 'provisioning_state': {'readonly': True}, 'state': {'readonly': True}, + 'creation_time': {'readonly': True}, + 'last_modified_time': {'readonly': True}, + 'endpoint': {'readonly': True}, + 'account_id': {'readonly': True}, 'default_data_lake_store_account': {'required': True}, 'max_degree_of_parallelism': {'minimum': 1}, 'query_store_retention': {'maximum': 180, 'minimum': 1}, @@ -130,9 +137,6 @@ class DataLakeAnalyticsAccount(Resource): 'system_max_degree_of_parallelism': {'readonly': True}, 'system_max_job_count': {'readonly': True}, 'data_lake_store_accounts': {'required': True}, - 'creation_time': {'readonly': True}, - 'last_modified_time': {'readonly': True}, - 'endpoint': {'readonly': True}, 'current_tier': {'readonly': True}, 'max_degree_of_parallelism_per_job': {'minimum': 1}, 'min_priority_per_job': {'minimum': 1}, @@ -146,6 +150,10 @@ class DataLakeAnalyticsAccount(Resource): 'tags': {'key': 'tags', 'type': '{str}'}, 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'DataLakeAnalyticsAccountStatus'}, 'state': {'key': 'properties.state', 'type': 'DataLakeAnalyticsAccountState'}, + 'creation_time': {'key': 'properties.creationTime', 'type': 'iso-8601'}, + 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, + 'endpoint': {'key': 'properties.endpoint', 'type': 'str'}, + 'account_id': {'key': 'properties.accountId', 'type': 'str'}, 'default_data_lake_store_account': {'key': 'properties.defaultDataLakeStoreAccount', 'type': 'str'}, 'max_degree_of_parallelism': {'key': 'properties.maxDegreeOfParallelism', 'type': 'int'}, 'query_store_retention': {'key': 'properties.queryStoreRetention', 'type': 'int'}, @@ -154,9 +162,6 @@ class DataLakeAnalyticsAccount(Resource): 'system_max_job_count': {'key': 'properties.systemMaxJobCount', 'type': 'int'}, 'data_lake_store_accounts': {'key': 'properties.dataLakeStoreAccounts', 'type': '[DataLakeStoreAccountInfo]'}, 'storage_accounts': {'key': 'properties.storageAccounts', 'type': '[StorageAccountInfo]'}, - 'creation_time': {'key': 'properties.creationTime', 'type': 'iso-8601'}, - 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, - 'endpoint': {'key': 'properties.endpoint', 'type': 'str'}, 'new_tier': {'key': 'properties.newTier', 'type': 'TierType'}, 'current_tier': {'key': 'properties.currentTier', 'type': 'TierType'}, 'firewall_state': {'key': 'properties.firewallState', 'type': 'FirewallState'}, @@ -171,6 +176,10 @@ def __init__(self, location, default_data_lake_store_account, data_lake_store_ac super(DataLakeAnalyticsAccount, self).__init__(location=location, tags=tags) self.provisioning_state = None self.state = None + self.creation_time = None + self.last_modified_time = None + self.endpoint = None + self.account_id = None self.default_data_lake_store_account = default_data_lake_store_account self.max_degree_of_parallelism = max_degree_of_parallelism self.query_store_retention = query_store_retention @@ -179,9 +188,6 @@ def __init__(self, location, default_data_lake_store_account, data_lake_store_ac self.system_max_job_count = None self.data_lake_store_accounts = data_lake_store_accounts self.storage_accounts = storage_accounts - self.creation_time = None - self.last_modified_time = None - self.endpoint = None self.new_tier = new_tier self.current_tier = None self.firewall_state = firewall_state diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_basic.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_basic.py new file mode 100644 index 000000000000..61b694f43d55 --- /dev/null +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_basic.py @@ -0,0 +1,87 @@ +# 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 .resource import Resource + + +class DataLakeAnalyticsAccountBasic(Resource): + """A Data Lake Analytics account object, containing all information associated + with the named Data Lake Analytics account. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource Id + :vartype id: str + :ivar name: Resource name + :vartype name: str + :ivar type: Resource type + :vartype type: str + :param location: Resource location + :type location: str + :param tags: Resource tags + :type tags: dict + :ivar provisioning_state: the provisioning status of the Data Lake + Analytics account. Possible values include: 'Failed', 'Creating', + 'Running', 'Succeeded', 'Patching', 'Suspending', 'Resuming', 'Deleting', + 'Deleted' + :vartype provisioning_state: str or :class:`DataLakeAnalyticsAccountStatus + ` + :ivar state: the state of the Data Lake Analytics account. Possible values + include: 'Active', 'Suspended' + :vartype state: str or :class:`DataLakeAnalyticsAccountState + ` + :ivar creation_time: the account creation time. + :vartype creation_time: datetime + :ivar last_modified_time: the account last modified time. + :vartype last_modified_time: datetime + :ivar endpoint: the full CName endpoint for this account. + :vartype endpoint: str + :ivar account_id: The unique identifier associated with this Data Lake + Analytics account. + :vartype account_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'location': {'required': True}, + 'provisioning_state': {'readonly': True}, + 'state': {'readonly': True}, + 'creation_time': {'readonly': True}, + 'last_modified_time': {'readonly': True}, + 'endpoint': {'readonly': True}, + 'account_id': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'location': {'key': 'location', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'DataLakeAnalyticsAccountStatus'}, + 'state': {'key': 'properties.state', 'type': 'DataLakeAnalyticsAccountState'}, + 'creation_time': {'key': 'properties.creationTime', 'type': 'iso-8601'}, + 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, + 'endpoint': {'key': 'properties.endpoint', 'type': 'str'}, + 'account_id': {'key': 'properties.accountId', 'type': 'str'}, + } + + def __init__(self, location, tags=None): + super(DataLakeAnalyticsAccountBasic, self).__init__(location=location, tags=tags) + self.provisioning_state = None + self.state = None + self.creation_time = None + self.last_modified_time = None + self.endpoint = None + self.account_id = None diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_paged.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_basic_paged.py similarity index 68% rename from azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_paged.py rename to azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_basic_paged.py index 8414cc6a7e5b..279867b941e2 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_paged.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_basic_paged.py @@ -12,16 +12,16 @@ from msrest.paging import Paged -class DataLakeAnalyticsAccountPaged(Paged): +class DataLakeAnalyticsAccountBasicPaged(Paged): """ - A paging container for iterating over a list of DataLakeAnalyticsAccount object + A paging container for iterating over a list of :class:`DataLakeAnalyticsAccountBasic ` object """ _attribute_map = { 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[DataLakeAnalyticsAccount]'} + 'current_page': {'key': 'value', 'type': '[DataLakeAnalyticsAccountBasic]'} } def __init__(self, *args, **kwargs): - super(DataLakeAnalyticsAccountPaged, self).__init__(*args, **kwargs) + super(DataLakeAnalyticsAccountBasicPaged, self).__init__(*args, **kwargs) diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_management_client_enums.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_management_client_enums.py index 33ef3e81f897..ed4a500305c3 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_management_client_enums.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_management_client_enums.py @@ -12,25 +12,6 @@ from enum import Enum -class DataLakeAnalyticsAccountStatus(Enum): - - failed = "Failed" - creating = "Creating" - running = "Running" - succeeded = "Succeeded" - patching = "Patching" - suspending = "Suspending" - resuming = "Resuming" - deleting = "Deleting" - deleted = "Deleted" - - -class DataLakeAnalyticsAccountState(Enum): - - active = "Active" - suspended = "Suspended" - - class TierType(Enum): consumption = "Consumption" @@ -61,3 +42,22 @@ class AADObjectType(Enum): user = "User" group = "Group" service_principal = "ServicePrincipal" + + +class DataLakeAnalyticsAccountStatus(Enum): + + failed = "Failed" + creating = "Creating" + running = "Running" + succeeded = "Succeeded" + patching = "Patching" + suspending = "Suspending" + resuming = "Resuming" + deleting = "Deleting" + deleted = "Deleted" + + +class DataLakeAnalyticsAccountState(Enum): + + active = "Active" + suspended = "Suspended" diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_properties_basic.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_properties_basic.py new file mode 100644 index 000000000000..9cfae99acc4a --- /dev/null +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_analytics_account_properties_basic.py @@ -0,0 +1,67 @@ +# 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 DataLakeAnalyticsAccountPropertiesBasic(Model): + """The basic account specific properties that are associated with an + underlying Data Lake Analytics account. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar provisioning_state: the provisioning status of the Data Lake + Analytics account. Possible values include: 'Failed', 'Creating', + 'Running', 'Succeeded', 'Patching', 'Suspending', 'Resuming', 'Deleting', + 'Deleted' + :vartype provisioning_state: str or :class:`DataLakeAnalyticsAccountStatus + ` + :ivar state: the state of the Data Lake Analytics account. Possible values + include: 'Active', 'Suspended' + :vartype state: str or :class:`DataLakeAnalyticsAccountState + ` + :ivar creation_time: the account creation time. + :vartype creation_time: datetime + :ivar last_modified_time: the account last modified time. + :vartype last_modified_time: datetime + :ivar endpoint: the full CName endpoint for this account. + :vartype endpoint: str + :ivar account_id: The unique identifier associated with this Data Lake + Analytics account. + :vartype account_id: str + """ + + _validation = { + 'provisioning_state': {'readonly': True}, + 'state': {'readonly': True}, + 'creation_time': {'readonly': True}, + 'last_modified_time': {'readonly': True}, + 'endpoint': {'readonly': True}, + 'account_id': {'readonly': True}, + } + + _attribute_map = { + 'provisioning_state': {'key': 'provisioningState', 'type': 'DataLakeAnalyticsAccountStatus'}, + 'state': {'key': 'state', 'type': 'DataLakeAnalyticsAccountState'}, + 'creation_time': {'key': 'creationTime', 'type': 'iso-8601'}, + 'last_modified_time': {'key': 'lastModifiedTime', 'type': 'iso-8601'}, + 'endpoint': {'key': 'endpoint', 'type': 'str'}, + 'account_id': {'key': 'accountId', 'type': 'str'}, + } + + def __init__(self): + self.provisioning_state = None + self.state = None + self.creation_time = None + self.last_modified_time = None + self.endpoint = None + self.account_id = None diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_store_account_info_paged.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_store_account_info_paged.py index 47a560ec3c20..e3f82dc99f38 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_store_account_info_paged.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/data_lake_store_account_info_paged.py @@ -14,7 +14,7 @@ class DataLakeStoreAccountInfoPaged(Paged): """ - A paging container for iterating over a list of DataLakeStoreAccountInfo object + A paging container for iterating over a list of :class:`DataLakeStoreAccountInfo ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/firewall_rule_paged.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/firewall_rule_paged.py index 90cd653ec5f8..20614418048d 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/firewall_rule_paged.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/firewall_rule_paged.py @@ -14,7 +14,7 @@ class FirewallRulePaged(Paged): """ - A paging container for iterating over a list of FirewallRule object + A paging container for iterating over a list of :class:`FirewallRule ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/sas_token_info_paged.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/sas_token_info_paged.py index d5c653acef0f..42eb70a31505 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/sas_token_info_paged.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/sas_token_info_paged.py @@ -14,7 +14,7 @@ class SasTokenInfoPaged(Paged): """ - A paging container for iterating over a list of SasTokenInfo object + A paging container for iterating over a list of :class:`SasTokenInfo ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_account_info_paged.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_account_info_paged.py index c7bae48ae50b..ed2c07040833 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_account_info_paged.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_account_info_paged.py @@ -14,7 +14,7 @@ class StorageAccountInfoPaged(Paged): """ - A paging container for iterating over a list of StorageAccountInfo object + A paging container for iterating over a list of :class:`StorageAccountInfo ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container.py index 5a4c865a99df..7280a7e2f181 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container.py @@ -18,10 +18,10 @@ class StorageContainer(Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar name: the name of the blob container. - :vartype name: str :ivar id: the unique identifier of the blob container. :vartype id: str + :ivar name: the name of the blob container. + :vartype name: str :ivar type: the type of the blob container. :vartype type: str :ivar last_modified_time: the last modified time of the blob container. @@ -29,21 +29,21 @@ class StorageContainer(Model): """ _validation = { - 'name': {'readonly': True}, 'id': {'readonly': True}, + 'name': {'readonly': True}, 'type': {'readonly': True}, 'last_modified_time': {'readonly': True}, } _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, 'type': {'key': 'type', 'type': 'str'}, 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, } def __init__(self): - self.name = None self.id = None + self.name = None self.type = None self.last_modified_time = None diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container_paged.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container_paged.py index b036e9e69d3c..c18b0555a334 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container_paged.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/models/storage_container_paged.py @@ -14,7 +14,7 @@ class StorageContainerPaged(Paged): """ - A paging container for iterating over a list of StorageContainer object + A paging container for iterating over a list of :class:`StorageContainer ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/account_operations.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/account_operations.py index 826621c90f29..01d16fd0d0c1 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/account_operations.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/account_operations.py @@ -9,10 +9,10 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError from msrestazure.azure_operation import AzureOperationPoller -import uuid from .. import models @@ -69,8 +69,11 @@ def list_by_resource_group( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: :class:`DataLakeAnalyticsAccountPaged - ` + :return: An iterator like instance of + :class:`DataLakeAnalyticsAccountBasic + ` + :rtype: :class:`DataLakeAnalyticsAccountBasicPaged + ` :raises: :class:`CloudError` """ def internal_paging(next_link=None, raw=False): @@ -127,11 +130,11 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.DataLakeAnalyticsAccountPaged(internal_paging, self._deserialize.dependencies) + deserialized = models.DataLakeAnalyticsAccountBasicPaged(internal_paging, self._deserialize.dependencies) if raw: header_dict = {} - client_raw_response = models.DataLakeAnalyticsAccountPaged(internal_paging, self._deserialize.dependencies, header_dict) + client_raw_response = models.DataLakeAnalyticsAccountBasicPaged(internal_paging, self._deserialize.dependencies, header_dict) return client_raw_response return deserialized @@ -166,8 +169,11 @@ def list( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: :class:`DataLakeAnalyticsAccountPaged - ` + :return: An iterator like instance of + :class:`DataLakeAnalyticsAccountBasic + ` + :rtype: :class:`DataLakeAnalyticsAccountBasicPaged + ` :raises: :class:`CloudError` """ def internal_paging(next_link=None, raw=False): @@ -223,34 +229,43 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.DataLakeAnalyticsAccountPaged(internal_paging, self._deserialize.dependencies) + deserialized = models.DataLakeAnalyticsAccountBasicPaged(internal_paging, self._deserialize.dependencies) if raw: header_dict = {} - client_raw_response = models.DataLakeAnalyticsAccountPaged(internal_paging, self._deserialize.dependencies, header_dict) + client_raw_response = models.DataLakeAnalyticsAccountBasicPaged(internal_paging, self._deserialize.dependencies, header_dict) return client_raw_response return deserialized - def get( - self, resource_group_name, account_name, custom_headers=None, raw=False, **operation_config): - """Gets details of the specified Data Lake Analytics account. + def create( + self, resource_group_name, account_name, parameters, custom_headers=None, raw=False, **operation_config): + """Creates the specified Data Lake Analytics account. This supplies the + user with computation services for Data Lake Analytics workloads. :param resource_group_name: The name of the Azure resource group that - contains the Data Lake Analytics account. + contains the Data Lake Analytics account.the account will be + associated with. :type resource_group_name: str :param account_name: The name of the Data Lake Analytics account to - retrieve. + create. :type account_name: str + :param parameters: Parameters supplied to the create Data Lake + Analytics account operation. + :type parameters: :class:`DataLakeAnalyticsAccount + ` :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response - :param operation_config: :ref:`Operation configuration - overrides`. - :rtype: :class:`DataLakeAnalyticsAccount + :return: + :class:`AzureOperationPoller` + instance that returns :class:`DataLakeAnalyticsAccount ` - :rtype: :class:`ClientRawResponse` - if raw=true + or :class:`ClientRawResponse` if + raw=true + :rtype: + :class:`AzureOperationPoller` + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -276,45 +291,82 @@ def get( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + # Construct body + body_content = self._serialize.body(parameters, 'DataLakeAnalyticsAccount') + # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, **operation_config) + def long_running_send(): - if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + request = self._client.put(url, query_parameters) + return self._client.send( + request, header_parameters, body_content, **operation_config) - deserialized = None + def get_long_running_status(status_link, headers=None): - if response.status_code == 200: - deserialized = self._deserialize('DataLakeAnalyticsAccount', response) + request = self._client.get(status_link) + if headers: + request.headers.update(headers) + return self._client.send( + request, header_parameters, **operation_config) + + def get_long_running_output(response): + + if response.status_code not in [201, 200]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 201: + deserialized = self._deserialize('DataLakeAnalyticsAccount', response) + if response.status_code == 200: + deserialized = self._deserialize('DataLakeAnalyticsAccount', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized if raw: - client_raw_response = ClientRawResponse(deserialized, response) - return client_raw_response + response = long_running_send() + return get_long_running_output(response) - return deserialized + long_running_operation_timeout = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + return AzureOperationPoller( + long_running_send, get_long_running_output, + get_long_running_status, long_running_operation_timeout) - def delete( - self, resource_group_name, account_name, custom_headers=None, raw=False, **operation_config): - """Begins the delete delete process for the Data Lake Analytics account - object specified by the account name. + def update( + self, resource_group_name, account_name, parameters=None, custom_headers=None, raw=False, **operation_config): + """Updates the Data Lake Analytics account object specified by the + accountName with the contents of the account object. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str :param account_name: The name of the Data Lake Analytics account to - delete + update. :type account_name: str + :param parameters: Parameters supplied to the update Data Lake + Analytics account operation. + :type parameters: :class:`DataLakeAnalyticsAccountUpdateParameters + ` :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response + :return: + :class:`AzureOperationPoller` + instance that returns :class:`DataLakeAnalyticsAccount + ` + or :class:`ClientRawResponse` if + raw=true :rtype: :class:`AzureOperationPoller` - instance that returns None - :rtype: :class:`ClientRawResponse` - if raw=true + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -340,11 +392,18 @@ def delete( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + # Construct body + if parameters is not None: + body_content = self._serialize.body(parameters, 'DataLakeAnalyticsAccountUpdateParameters') + else: + body_content = None + # Construct and send request def long_running_send(): - request = self._client.delete(url, query_parameters) - return self._client.send(request, header_parameters, **operation_config) + request = self._client.patch(url, query_parameters) + return self._client.send( + request, header_parameters, body_content, **operation_config) def get_long_running_status(status_link, headers=None): @@ -356,15 +415,24 @@ def get_long_running_status(status_link, headers=None): def get_long_running_output(response): - if response.status_code not in [200, 202, 204]: + if response.status_code not in [200, 201]: exp = CloudError(response) exp.request_id = response.headers.get('x-ms-request-id') raise exp + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('DataLakeAnalyticsAccount', response) + if response.status_code == 201: + deserialized = self._deserialize('DataLakeAnalyticsAccount', response) + if raw: - client_raw_response = ClientRawResponse(None, response) + client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response + return deserialized + if raw: response = long_running_send() return get_long_running_output(response) @@ -376,31 +444,28 @@ def get_long_running_output(response): long_running_send, get_long_running_output, get_long_running_status, long_running_operation_timeout) - def create( - self, resource_group_name, account_name, parameters, custom_headers=None, raw=False, **operation_config): - """Creates the specified Data Lake Analytics account. This supplies the - user with computation services for Data Lake Analytics workloads. + def delete( + self, resource_group_name, account_name, custom_headers=None, raw=False, **operation_config): + """Begins the delete process for the Data Lake Analytics account object + specified by the account name. :param resource_group_name: The name of the Azure resource group that - contains the Data Lake Analytics account.the account will be - associated with. + contains the Data Lake Analytics account. :type resource_group_name: str :param account_name: The name of the Data Lake Analytics account to - create. + delete :type account_name: str - :param parameters: Parameters supplied to the create Data Lake - Analytics account operation. - :type parameters: :class:`DataLakeAnalyticsAccount - ` :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response + :return: + :class:`AzureOperationPoller` + instance that returns None or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`AzureOperationPoller` - instance that returns :class:`DataLakeAnalyticsAccount - ` - :rtype: :class:`ClientRawResponse` - if raw=true + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -426,15 +491,11 @@ def create( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - # Construct body - body_content = self._serialize.body(parameters, 'DataLakeAnalyticsAccount') - # Construct and send request def long_running_send(): - request = self._client.put(url, query_parameters) - return self._client.send( - request, header_parameters, body_content, **operation_config) + request = self._client.delete(url, query_parameters) + return self._client.send(request, header_parameters, **operation_config) def get_long_running_status(status_link, headers=None): @@ -446,24 +507,15 @@ def get_long_running_status(status_link, headers=None): def get_long_running_output(response): - if response.status_code not in [201, 200]: + if response.status_code not in [200, 202, 204]: exp = CloudError(response) exp.request_id = response.headers.get('x-ms-request-id') raise exp - deserialized = None - - if response.status_code == 201: - deserialized = self._deserialize('DataLakeAnalyticsAccount', response) - if response.status_code == 200: - deserialized = self._deserialize('DataLakeAnalyticsAccount', response) - if raw: - client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response = ClientRawResponse(None, response) return client_raw_response - return deserialized - if raw: response = long_running_send() return get_long_running_output(response) @@ -475,30 +527,28 @@ def get_long_running_output(response): long_running_send, get_long_running_output, get_long_running_status, long_running_operation_timeout) - def update( - self, resource_group_name, account_name, parameters=None, custom_headers=None, raw=False, **operation_config): - """Updates the Data Lake Analytics account object specified by the - accountName with the contents of the account object. + def get( + self, resource_group_name, account_name, custom_headers=None, raw=False, **operation_config): + """Gets details of the specified Data Lake Analytics account. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str :param account_name: The name of the Data Lake Analytics account to - update. + retrieve. :type account_name: str - :param parameters: Parameters supplied to the update Data Lake - Analytics account operation. - :type parameters: :class:`DataLakeAnalyticsAccountUpdateParameters - ` :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response - :rtype: - :class:`AzureOperationPoller` - instance that returns :class:`DataLakeAnalyticsAccount + :param operation_config: :ref:`Operation configuration + overrides`. + :return: :class:`DataLakeAnalyticsAccount ` - :rtype: :class:`ClientRawResponse` - if raw=true + or :class:`ClientRawResponse` if + raw=true + :rtype: :class:`DataLakeAnalyticsAccount + ` + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -524,54 +574,22 @@ def update( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - # Construct body - if parameters is not None: - body_content = self._serialize.body(parameters, 'DataLakeAnalyticsAccountUpdateParameters') - else: - body_content = None - # Construct and send request - def long_running_send(): - - request = self._client.patch(url, query_parameters) - return self._client.send( - request, header_parameters, body_content, **operation_config) - - def get_long_running_status(status_link, headers=None): - - request = self._client.get(status_link) - if headers: - request.headers.update(headers) - return self._client.send( - request, header_parameters, **operation_config) - - def get_long_running_output(response): - - if response.status_code not in [200, 201]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - deserialized = None + request = self._client.get(url, query_parameters) + response = self._client.send(request, header_parameters, **operation_config) - if response.status_code == 200: - deserialized = self._deserialize('DataLakeAnalyticsAccount', response) - if response.status_code == 201: - deserialized = self._deserialize('DataLakeAnalyticsAccount', response) + if response.status_code not in [200]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - return client_raw_response + deserialized = None - return deserialized + if response.status_code == 200: + deserialized = self._deserialize('DataLakeAnalyticsAccount', response) if raw: - response = long_running_send() - return get_long_running_output(response) + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response - long_running_operation_timeout = operation_config.get( - 'long_running_operation_timeout', - self.config.long_running_operation_timeout) - return AzureOperationPoller( - long_running_send, get_long_running_output, - get_long_running_status, long_running_operation_timeout) + return deserialized diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/compute_policies_operations.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/compute_policies_operations.py index 2d229e429bdf..1dae436a6aff 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/compute_policies_operations.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/compute_policies_operations.py @@ -9,9 +9,9 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError -import uuid from .. import models @@ -60,10 +60,13 @@ def create_or_update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`ComputePolicy + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`ComputePolicy - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -137,10 +140,13 @@ def update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`ComputePolicy + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`ComputePolicy - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ parameters = None @@ -216,9 +222,11 @@ def delete( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -276,10 +284,13 @@ def get( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`ComputePolicy + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`ComputePolicy - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -342,6 +353,8 @@ def list_by_account( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`ComputePolicy + ` :rtype: :class:`ComputePolicyPaged ` :raises: :class:`CloudError` diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/data_lake_store_accounts_operations.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/data_lake_store_accounts_operations.py index de8aab91ce5e..e7146df9c79e 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/data_lake_store_accounts_operations.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/data_lake_store_accounts_operations.py @@ -9,9 +9,9 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError -import uuid from .. import models @@ -35,31 +35,38 @@ def __init__(self, client, config, serializer, deserializer): self.config = config - def get( - self, resource_group_name, account_name, data_lake_store_account_name, custom_headers=None, raw=False, **operation_config): - """Gets the specified Data Lake Store account details in the specified - Data Lake Analytics account. + def add( + self, resource_group_name, account_name, data_lake_store_account_name, suffix=None, custom_headers=None, raw=False, **operation_config): + """Updates the specified Data Lake Analytics account to include the + additional Data Lake Store account. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str - :param account_name: The name of the Data Lake Analytics account from - which to retrieve the Data Lake Store account details. + :param account_name: The name of the Data Lake Analytics account to + which to add the Data Lake Store account. :type account_name: str :param data_lake_store_account_name: The name of the Data Lake Store - account to retrieve + account to add. :type data_lake_store_account_name: str + :param suffix: the optional suffix for the Data Lake Store account. + :type suffix: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: :class:`DataLakeStoreAccountInfo - ` - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ + parameters = None + if suffix is not None: + parameters = models.AddDataLakeStoreParameters(suffix=suffix) + # Construct URL url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/DataLakeStoreAccounts/{dataLakeStoreAccountName}' path_format_arguments = { @@ -84,26 +91,26 @@ def get( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + # Construct body + if parameters is not None: + body_content = self._serialize.body(parameters, 'AddDataLakeStoreParameters') + else: + body_content = None + # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, **operation_config) + request = self._client.put(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, **operation_config) if response.status_code not in [200]: exp = CloudError(response) exp.request_id = response.headers.get('x-ms-request-id') raise exp - deserialized = None - - if response.status_code == 200: - deserialized = self._deserialize('DataLakeStoreAccountInfo', response) - if raw: - client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response = ClientRawResponse(None, response) return client_raw_response - return deserialized - def delete( self, resource_group_name, account_name, data_lake_store_account_name, custom_headers=None, raw=False, **operation_config): """Updates the Data Lake Analytics account specified to remove the @@ -123,9 +130,11 @@ def delete( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -165,36 +174,34 @@ def delete( client_raw_response = ClientRawResponse(None, response) return client_raw_response - def add( - self, resource_group_name, account_name, data_lake_store_account_name, suffix=None, custom_headers=None, raw=False, **operation_config): - """Updates the specified Data Lake Analytics account to include the - additional Data Lake Store account. + def get( + self, resource_group_name, account_name, data_lake_store_account_name, custom_headers=None, raw=False, **operation_config): + """Gets the specified Data Lake Store account details in the specified + Data Lake Analytics account. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str - :param account_name: The name of the Data Lake Analytics account to - which to add the Data Lake Store account. + :param account_name: The name of the Data Lake Analytics account from + which to retrieve the Data Lake Store account details. :type account_name: str :param data_lake_store_account_name: The name of the Data Lake Store - account to add. + account to retrieve :type data_lake_store_account_name: str - :param suffix: the optional suffix for the Data Lake Store account. - :type suffix: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: :class:`DataLakeStoreAccountInfo + ` + or :class:`ClientRawResponse` if + raw=true + :rtype: :class:`DataLakeStoreAccountInfo + ` + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ - parameters = None - if suffix is not None: - parameters = models.AddDataLakeStoreParameters(suffix=suffix) - # Construct URL url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/DataLakeStoreAccounts/{dataLakeStoreAccountName}' path_format_arguments = { @@ -219,26 +226,26 @@ def add( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - # Construct body - if parameters is not None: - body_content = self._serialize.body(parameters, 'AddDataLakeStoreParameters') - else: - body_content = None - # Construct and send request - request = self._client.put(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, **operation_config) + request = self._client.get(url, query_parameters) + response = self._client.send(request, header_parameters, **operation_config) if response.status_code not in [200]: exp = CloudError(response) exp.request_id = response.headers.get('x-ms-request-id') raise exp + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('DataLakeStoreAccountInfo', response) + if raw: - client_raw_response = ClientRawResponse(None, response) + client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response + return deserialized + def list_by_account( self, resource_group_name, account_name, filter=None, top=None, skip=None, select=None, orderby=None, count=None, custom_headers=None, raw=False, **operation_config): """Gets the first page of Data Lake Store accounts linked to the specified @@ -276,6 +283,8 @@ def list_by_account( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`DataLakeStoreAccountInfo + ` :rtype: :class:`DataLakeStoreAccountInfoPaged ` :raises: :class:`CloudError` diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/firewall_rules_operations.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/firewall_rules_operations.py index 5f59d12de725..abe419d78f83 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/firewall_rules_operations.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/firewall_rules_operations.py @@ -9,9 +9,9 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError -import uuid from .. import models @@ -59,10 +59,13 @@ def create_or_update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`FirewallRule + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`FirewallRule - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -138,10 +141,13 @@ def update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`FirewallRule + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`FirewallRule - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ parameters = None @@ -217,9 +223,11 @@ def delete( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -276,10 +284,13 @@ def get( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`FirewallRule + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`FirewallRule - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -342,6 +353,8 @@ def list_by_account( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`FirewallRule + ` :rtype: :class:`FirewallRulePaged ` :raises: :class:`CloudError` diff --git a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/storage_accounts_operations.py b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/storage_accounts_operations.py index 8df2c5601f2f..76481dbb5295 100644 --- a/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/storage_accounts_operations.py +++ b/azure-mgmt-datalake-analytics/azure/mgmt/datalake/analytics/account/operations/storage_accounts_operations.py @@ -9,9 +9,9 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError -import uuid from .. import models @@ -35,31 +35,39 @@ def __init__(self, client, config, serializer, deserializer): self.config = config - def get( - self, resource_group_name, account_name, storage_account_name, custom_headers=None, raw=False, **operation_config): - """Gets the specified Azure Storage account linked to the given Data Lake - Analytics account. + def add( + self, resource_group_name, account_name, storage_account_name, access_key, suffix=None, custom_headers=None, raw=False, **operation_config): + """Updates the specified Data Lake Analytics account to add an Azure + Storage account. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str - :param account_name: The name of the Data Lake Analytics account from - which to retrieve Azure storage account details. + :param account_name: The name of the Data Lake Analytics account to + which to add the Azure Storage account. :type account_name: str - :param storage_account_name: The name of the Azure Storage account for - which to retrieve the details. + :param storage_account_name: The name of the Azure Storage account to + add :type storage_account_name: str + :param access_key: the access key associated with this Azure Storage + account that will be used to connect to it. + :type access_key: str + :param suffix: the optional suffix for the storage account. + :type suffix: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: :class:`StorageAccountInfo - ` - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ + parameters = models.AddStorageAccountParameters(access_key=access_key, suffix=suffix) + # Construct URL url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/StorageAccounts/{storageAccountName}' path_format_arguments = { @@ -84,50 +92,57 @@ def get( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + # Construct body + body_content = self._serialize.body(parameters, 'AddStorageAccountParameters') + # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, **operation_config) + request = self._client.put(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, **operation_config) if response.status_code not in [200]: exp = CloudError(response) exp.request_id = response.headers.get('x-ms-request-id') raise exp - deserialized = None - - if response.status_code == 200: - deserialized = self._deserialize('StorageAccountInfo', response) - if raw: - client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response = ClientRawResponse(None, response) return client_raw_response - return deserialized - - def delete( - self, resource_group_name, account_name, storage_account_name, custom_headers=None, raw=False, **operation_config): - """Updates the specified Data Lake Analytics account to remove an Azure - Storage account. + def update( + self, resource_group_name, account_name, storage_account_name, access_key=None, suffix=None, custom_headers=None, raw=False, **operation_config): + """Updates the Data Lake Analytics account to replace Azure Storage blob + account details, such as the access key and/or suffix. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str - :param account_name: The name of the Data Lake Analytics account from - which to remove the Azure Storage account. + :param account_name: The name of the Data Lake Analytics account to + modify storage accounts in :type account_name: str - :param storage_account_name: The name of the Azure Storage account to - remove + :param storage_account_name: The Azure Storage account to modify :type storage_account_name: str + :param access_key: the updated access key associated with this Azure + Storage account that will be used to connect to it. + :type access_key: str + :param suffix: the optional suffix for the storage account. + :type suffix: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ + parameters = None + if access_key is not None or suffix is not None: + parameters = models.UpdateStorageAccountParameters(access_key=access_key, suffix=suffix) + # Construct URL url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/StorageAccounts/{storageAccountName}' path_format_arguments = { @@ -152,9 +167,16 @@ def delete( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + # Construct body + if parameters is not None: + body_content = self._serialize.body(parameters, 'UpdateStorageAccountParameters') + else: + body_content = None + # Construct and send request - request = self._client.delete(url, query_parameters) - response = self._client.send(request, header_parameters, **operation_config) + request = self._client.patch(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -165,38 +187,32 @@ def delete( client_raw_response = ClientRawResponse(None, response) return client_raw_response - def update( - self, resource_group_name, account_name, storage_account_name, access_key=None, suffix=None, custom_headers=None, raw=False, **operation_config): - """Updates the Data Lake Analytics account to replace Azure Storage blob - account details, such as the access key and/or suffix. + def delete( + self, resource_group_name, account_name, storage_account_name, custom_headers=None, raw=False, **operation_config): + """Updates the specified Data Lake Analytics account to remove an Azure + Storage account. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str - :param account_name: The name of the Data Lake Analytics account to - modify storage accounts in + :param account_name: The name of the Data Lake Analytics account from + which to remove the Azure Storage account. :type account_name: str - :param storage_account_name: The Azure Storage account to modify + :param storage_account_name: The name of the Azure Storage account to + remove :type storage_account_name: str - :param access_key: the updated access key associated with this Azure - Storage account that will be used to connect to it. - :type access_key: str - :param suffix: the optional suffix for the storage account. - :type suffix: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ - parameters = None - if access_key is not None or suffix is not None: - parameters = models.UpdateStorageAccountParameters(access_key=access_key, suffix=suffix) - # Construct URL url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/StorageAccounts/{storageAccountName}' path_format_arguments = { @@ -221,16 +237,9 @@ def update( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - # Construct body - if parameters is not None: - body_content = self._serialize.body(parameters, 'UpdateStorageAccountParameters') - else: - body_content = None - # Construct and send request - request = self._client.patch(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, **operation_config) + request = self._client.delete(url, query_parameters) + response = self._client.send(request, header_parameters, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -241,37 +250,34 @@ def update( client_raw_response = ClientRawResponse(None, response) return client_raw_response - def add( - self, resource_group_name, account_name, storage_account_name, access_key, suffix=None, custom_headers=None, raw=False, **operation_config): - """Updates the specified Data Lake Analytics account to add an Azure - Storage account. + def get( + self, resource_group_name, account_name, storage_account_name, custom_headers=None, raw=False, **operation_config): + """Gets the specified Azure Storage account linked to the given Data Lake + Analytics account. :param resource_group_name: The name of the Azure resource group that contains the Data Lake Analytics account. :type resource_group_name: str - :param account_name: The name of the Data Lake Analytics account to - which to add the Azure Storage account. + :param account_name: The name of the Data Lake Analytics account from + which to retrieve Azure storage account details. :type account_name: str - :param storage_account_name: The name of the Azure Storage account to - add + :param storage_account_name: The name of the Azure Storage account for + which to retrieve the details. :type storage_account_name: str - :param access_key: the access key associated with this Azure Storage - account that will be used to connect to it. - :type access_key: str - :param suffix: the optional suffix for the storage account. - :type suffix: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: :class:`StorageAccountInfo + ` or + :class:`ClientRawResponse` if + raw=true + :rtype: :class:`StorageAccountInfo + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ - parameters = models.AddStorageAccountParameters(access_key=access_key, suffix=suffix) - # Construct URL url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/StorageAccounts/{storageAccountName}' path_format_arguments = { @@ -296,23 +302,26 @@ def add( if self.config.accept_language is not None: header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - # Construct body - body_content = self._serialize.body(parameters, 'AddStorageAccountParameters') - # Construct and send request - request = self._client.put(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, **operation_config) + request = self._client.get(url, query_parameters) + response = self._client.send(request, header_parameters, **operation_config) if response.status_code not in [200]: exp = CloudError(response) exp.request_id = response.headers.get('x-ms-request-id') raise exp + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('StorageAccountInfo', response) + if raw: - client_raw_response = ClientRawResponse(None, response) + client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response + return deserialized + def get_storage_container( self, resource_group_name, account_name, storage_account_name, container_name, custom_headers=None, raw=False, **operation_config): """Gets the specified Azure Storage container associated with the given @@ -335,10 +344,13 @@ def get_storage_container( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`StorageContainer + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`StorageContainer - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -406,6 +418,8 @@ def list_storage_containers( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`StorageContainer + ` :rtype: :class:`StorageContainerPaged ` :raises: :class:`CloudError` @@ -485,6 +499,8 @@ def list_sas_tokens( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`SasTokenInfo + ` :rtype: :class:`SasTokenInfoPaged ` :raises: :class:`CloudError` @@ -580,6 +596,8 @@ def list_by_account( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`StorageAccountInfo + ` :rtype: :class:`StorageAccountInfoPaged ` :raises: :class:`CloudError` diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/__init__.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/__init__.py index 3207400a1bca..faf516d80a99 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/__init__.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/__init__.py @@ -20,22 +20,23 @@ from .update_encryption_config import UpdateEncryptionConfig from .data_lake_store_account_update_parameters import DataLakeStoreAccountUpdateParameters from .data_lake_store_account import DataLakeStoreAccount +from .data_lake_store_account_basic import DataLakeStoreAccountBasic from .error_details import ErrorDetails from .resource import Resource from .sub_resource import SubResource from .firewall_rule_paged import FirewallRulePaged from .trusted_id_provider_paged import TrustedIdProviderPaged -from .data_lake_store_account_paged import DataLakeStoreAccountPaged +from .data_lake_store_account_basic_paged import DataLakeStoreAccountBasicPaged from .data_lake_store_account_management_client_enums import ( EncryptionConfigType, - DataLakeStoreAccountStatus, - DataLakeStoreAccountState, EncryptionState, EncryptionProvisioningState, FirewallState, TrustedIdProviderState, TierType, FirewallAllowAzureIpsState, + DataLakeStoreAccountStatus, + DataLakeStoreAccountState, ) __all__ = [ @@ -50,19 +51,20 @@ 'UpdateEncryptionConfig', 'DataLakeStoreAccountUpdateParameters', 'DataLakeStoreAccount', + 'DataLakeStoreAccountBasic', 'ErrorDetails', 'Resource', 'SubResource', 'FirewallRulePaged', 'TrustedIdProviderPaged', - 'DataLakeStoreAccountPaged', + 'DataLakeStoreAccountBasicPaged', 'EncryptionConfigType', - 'DataLakeStoreAccountStatus', - 'DataLakeStoreAccountState', 'EncryptionState', 'EncryptionProvisioningState', 'FirewallState', 'TrustedIdProviderState', 'TierType', 'FirewallAllowAzureIpsState', + 'DataLakeStoreAccountStatus', + 'DataLakeStoreAccountState', ] diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account.py index 56a7325957d6..0decb5338664 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account.py @@ -31,18 +31,24 @@ class DataLakeStoreAccount(Resource): :param identity: The Key Vault encryption identity, if any. :type identity: :class:`EncryptionIdentity ` - :ivar provisioning_state: the status of the Data Lake Store account while - being provisioned. Possible values include: 'Failed', 'Creating', - 'Running', 'Succeeded', 'Patching', 'Suspending', 'Resuming', 'Deleting', - 'Deleted' + :ivar provisioning_state: the provisioning status of the Data Lake Store + account. Possible values include: 'Failed', 'Creating', 'Running', + 'Succeeded', 'Patching', 'Suspending', 'Resuming', 'Deleting', 'Deleted' :vartype provisioning_state: str or :class:`DataLakeStoreAccountStatus ` - :ivar state: the status of the Data Lake Store account after provisioning - has completed. Possible values include: 'Active', 'Suspended' + :ivar state: the state of the Data Lake Store account. Possible values + include: 'Active', 'Suspended' :vartype state: str or :class:`DataLakeStoreAccountState ` :ivar creation_time: the account creation time. :vartype creation_time: datetime + :ivar last_modified_time: the account last modified time. + :vartype last_modified_time: datetime + :ivar endpoint: the full CName endpoint for this account. + :vartype endpoint: str + :ivar account_id: The unique identifier associated with this Data Lake + Store account. + :vartype account_id: str :param encryption_state: The current state of encryption for this Data Lake store account. Possible values include: 'Enabled', 'Disabled' :type encryption_state: str or :class:`EncryptionState @@ -74,10 +80,6 @@ class DataLakeStoreAccount(Resource): associated with this Data Lake store account. :type trusted_id_providers: list of :class:`TrustedIdProvider ` - :ivar last_modified_time: the account last modified time. - :vartype last_modified_time: datetime - :ivar endpoint: the gateway host. - :vartype endpoint: str :param default_group: the default owner group for all new folders and files created in the Data Lake Store account. :type default_group: str @@ -108,9 +110,10 @@ class DataLakeStoreAccount(Resource): 'provisioning_state': {'readonly': True}, 'state': {'readonly': True}, 'creation_time': {'readonly': True}, - 'encryption_provisioning_state': {'readonly': True}, 'last_modified_time': {'readonly': True}, 'endpoint': {'readonly': True}, + 'account_id': {'readonly': True}, + 'encryption_provisioning_state': {'readonly': True}, 'current_tier': {'readonly': True}, } @@ -124,6 +127,9 @@ class DataLakeStoreAccount(Resource): 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'DataLakeStoreAccountStatus'}, 'state': {'key': 'properties.state', 'type': 'DataLakeStoreAccountState'}, 'creation_time': {'key': 'properties.creationTime', 'type': 'iso-8601'}, + 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, + 'endpoint': {'key': 'properties.endpoint', 'type': 'str'}, + 'account_id': {'key': 'properties.accountId', 'type': 'str'}, 'encryption_state': {'key': 'properties.encryptionState', 'type': 'EncryptionState'}, 'encryption_provisioning_state': {'key': 'properties.encryptionProvisioningState', 'type': 'EncryptionProvisioningState'}, 'encryption_config': {'key': 'properties.encryptionConfig', 'type': 'EncryptionConfig'}, @@ -131,8 +137,6 @@ class DataLakeStoreAccount(Resource): 'firewall_rules': {'key': 'properties.firewallRules', 'type': '[FirewallRule]'}, 'trusted_id_provider_state': {'key': 'properties.trustedIdProviderState', 'type': 'TrustedIdProviderState'}, 'trusted_id_providers': {'key': 'properties.trustedIdProviders', 'type': '[TrustedIdProvider]'}, - 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, - 'endpoint': {'key': 'properties.endpoint', 'type': 'str'}, 'default_group': {'key': 'properties.defaultGroup', 'type': 'str'}, 'new_tier': {'key': 'properties.newTier', 'type': 'TierType'}, 'current_tier': {'key': 'properties.currentTier', 'type': 'TierType'}, @@ -145,6 +149,9 @@ def __init__(self, location, tags=None, identity=None, encryption_state=None, en self.provisioning_state = None self.state = None self.creation_time = None + self.last_modified_time = None + self.endpoint = None + self.account_id = None self.encryption_state = encryption_state self.encryption_provisioning_state = None self.encryption_config = encryption_config @@ -152,8 +159,6 @@ def __init__(self, location, tags=None, identity=None, encryption_state=None, en self.firewall_rules = firewall_rules self.trusted_id_provider_state = trusted_id_provider_state self.trusted_id_providers = trusted_id_providers - self.last_modified_time = None - self.endpoint = None self.default_group = default_group self.new_tier = new_tier self.current_tier = None diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_basic.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_basic.py new file mode 100644 index 000000000000..9e200cd83459 --- /dev/null +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_basic.py @@ -0,0 +1,85 @@ +# 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 .resource import Resource + + +class DataLakeStoreAccountBasic(Resource): + """Basic Data Lake Store account information, returned on list calls. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource Id + :vartype id: str + :ivar name: Resource name + :vartype name: str + :ivar type: Resource type + :vartype type: str + :param location: Resource location + :type location: str + :param tags: Resource tags + :type tags: dict + :ivar provisioning_state: the provisioning status of the Data Lake Store + account. Possible values include: 'Failed', 'Creating', 'Running', + 'Succeeded', 'Patching', 'Suspending', 'Resuming', 'Deleting', 'Deleted' + :vartype provisioning_state: str or :class:`DataLakeStoreAccountStatus + ` + :ivar state: the state of the Data Lake Store account. Possible values + include: 'Active', 'Suspended' + :vartype state: str or :class:`DataLakeStoreAccountState + ` + :ivar creation_time: the account creation time. + :vartype creation_time: datetime + :ivar last_modified_time: the account last modified time. + :vartype last_modified_time: datetime + :ivar endpoint: the full CName endpoint for this account. + :vartype endpoint: str + :ivar account_id: The unique identifier associated with this Data Lake + Store account. + :vartype account_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'location': {'required': True}, + 'provisioning_state': {'readonly': True}, + 'state': {'readonly': True}, + 'creation_time': {'readonly': True}, + 'last_modified_time': {'readonly': True}, + 'endpoint': {'readonly': True}, + 'account_id': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'location': {'key': 'location', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'DataLakeStoreAccountStatus'}, + 'state': {'key': 'properties.state', 'type': 'DataLakeStoreAccountState'}, + 'creation_time': {'key': 'properties.creationTime', 'type': 'iso-8601'}, + 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, + 'endpoint': {'key': 'properties.endpoint', 'type': 'str'}, + 'account_id': {'key': 'properties.accountId', 'type': 'str'}, + } + + def __init__(self, location, tags=None): + super(DataLakeStoreAccountBasic, self).__init__(location=location, tags=tags) + self.provisioning_state = None + self.state = None + self.creation_time = None + self.last_modified_time = None + self.endpoint = None + self.account_id = None diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_paged.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_basic_paged.py similarity index 70% rename from azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_paged.py rename to azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_basic_paged.py index 3bbaebca0ddf..61a413fcb2b3 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_paged.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_basic_paged.py @@ -12,16 +12,16 @@ from msrest.paging import Paged -class DataLakeStoreAccountPaged(Paged): +class DataLakeStoreAccountBasicPaged(Paged): """ - A paging container for iterating over a list of DataLakeStoreAccount object + A paging container for iterating over a list of :class:`DataLakeStoreAccountBasic ` object """ _attribute_map = { 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[DataLakeStoreAccount]'} + 'current_page': {'key': 'value', 'type': '[DataLakeStoreAccountBasic]'} } def __init__(self, *args, **kwargs): - super(DataLakeStoreAccountPaged, self).__init__(*args, **kwargs) + super(DataLakeStoreAccountBasicPaged, self).__init__(*args, **kwargs) diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_management_client_enums.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_management_client_enums.py index 9bbd464c8919..eecabf9ea0b7 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_management_client_enums.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/data_lake_store_account_management_client_enums.py @@ -18,25 +18,6 @@ class EncryptionConfigType(Enum): service_managed = "ServiceManaged" -class DataLakeStoreAccountStatus(Enum): - - failed = "Failed" - creating = "Creating" - running = "Running" - succeeded = "Succeeded" - patching = "Patching" - suspending = "Suspending" - resuming = "Resuming" - deleting = "Deleting" - deleted = "Deleted" - - -class DataLakeStoreAccountState(Enum): - - active = "Active" - suspended = "Suspended" - - class EncryptionState(Enum): enabled = "Enabled" @@ -76,3 +57,22 @@ class FirewallAllowAzureIpsState(Enum): enabled = "Enabled" disabled = "Disabled" + + +class DataLakeStoreAccountStatus(Enum): + + failed = "Failed" + creating = "Creating" + running = "Running" + succeeded = "Succeeded" + patching = "Patching" + suspending = "Suspending" + resuming = "Resuming" + deleting = "Deleting" + deleted = "Deleted" + + +class DataLakeStoreAccountState(Enum): + + active = "Active" + suspended = "Suspended" diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/firewall_rule_paged.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/firewall_rule_paged.py index 90cd653ec5f8..3db1c14e4e67 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/firewall_rule_paged.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/firewall_rule_paged.py @@ -14,7 +14,7 @@ class FirewallRulePaged(Paged): """ - A paging container for iterating over a list of FirewallRule object + A paging container for iterating over a list of :class:`FirewallRule ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/trusted_id_provider_paged.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/trusted_id_provider_paged.py index 9ca036e4ad26..27ffcf3c49e5 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/trusted_id_provider_paged.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/models/trusted_id_provider_paged.py @@ -14,7 +14,7 @@ class TrustedIdProviderPaged(Paged): """ - A paging container for iterating over a list of TrustedIdProvider object + A paging container for iterating over a list of :class:`TrustedIdProvider ` object """ _attribute_map = { diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/account_operations.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/account_operations.py index c1204c311483..7de5e4575995 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/account_operations.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/account_operations.py @@ -9,10 +9,10 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError from msrestazure.azure_operation import AzureOperationPoller -import uuid from .. import models @@ -52,12 +52,15 @@ def create( :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response - :rtype: + :return: :class:`AzureOperationPoller` instance that returns :class:`DataLakeStoreAccount - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` if + raw=true + :rtype: + :class:`AzureOperationPoller` + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -148,12 +151,15 @@ def update( :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response - :rtype: + :return: :class:`AzureOperationPoller` instance that returns :class:`DataLakeStoreAccount - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` if + raw=true + :rtype: + :class:`AzureOperationPoller` + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -240,11 +246,14 @@ def delete( :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response + :return: + :class:`AzureOperationPoller` + instance that returns None or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`AzureOperationPoller` - instance that returns None - :rtype: :class:`ClientRawResponse` - if raw=true + or :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -320,10 +329,13 @@ def get( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`DataLakeStoreAccount + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`DataLakeStoreAccount - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -385,9 +397,11 @@ def enable_key_vault( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -459,8 +473,11 @@ def list_by_resource_group( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: :class:`DataLakeStoreAccountPaged - ` + :return: An iterator like instance of + :class:`DataLakeStoreAccountBasic + ` + :rtype: :class:`DataLakeStoreAccountBasicPaged + ` :raises: :class:`CloudError` """ def internal_paging(next_link=None, raw=False): @@ -517,11 +534,11 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.DataLakeStoreAccountPaged(internal_paging, self._deserialize.dependencies) + deserialized = models.DataLakeStoreAccountBasicPaged(internal_paging, self._deserialize.dependencies) if raw: header_dict = {} - client_raw_response = models.DataLakeStoreAccountPaged(internal_paging, self._deserialize.dependencies, header_dict) + client_raw_response = models.DataLakeStoreAccountBasicPaged(internal_paging, self._deserialize.dependencies, header_dict) return client_raw_response return deserialized @@ -556,8 +573,11 @@ def list( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: :class:`DataLakeStoreAccountPaged - ` + :return: An iterator like instance of + :class:`DataLakeStoreAccountBasic + ` + :rtype: :class:`DataLakeStoreAccountBasicPaged + ` :raises: :class:`CloudError` """ def internal_paging(next_link=None, raw=False): @@ -613,11 +633,11 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.DataLakeStoreAccountPaged(internal_paging, self._deserialize.dependencies) + deserialized = models.DataLakeStoreAccountBasicPaged(internal_paging, self._deserialize.dependencies) if raw: header_dict = {} - client_raw_response = models.DataLakeStoreAccountPaged(internal_paging, self._deserialize.dependencies, header_dict) + client_raw_response = models.DataLakeStoreAccountBasicPaged(internal_paging, self._deserialize.dependencies, header_dict) return client_raw_response return deserialized diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/firewall_rules_operations.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/firewall_rules_operations.py index 1ace03aec813..56eb105ade09 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/firewall_rules_operations.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/firewall_rules_operations.py @@ -9,9 +9,9 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError -import uuid from .. import models @@ -59,10 +59,13 @@ def create_or_update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`FirewallRule + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`FirewallRule - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -138,10 +141,13 @@ def update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`FirewallRule + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`FirewallRule - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ parameters = None @@ -217,9 +223,11 @@ def delete( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -276,10 +284,13 @@ def get( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`FirewallRule + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`FirewallRule - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -342,6 +353,8 @@ def list_by_account( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`FirewallRule + ` :rtype: :class:`FirewallRulePaged ` :raises: :class:`CloudError` diff --git a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/trusted_id_providers_operations.py b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/trusted_id_providers_operations.py index b62e68174f42..52a359914005 100644 --- a/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/trusted_id_providers_operations.py +++ b/azure-mgmt-datalake-store/azure/mgmt/datalake/store/operations/trusted_id_providers_operations.py @@ -9,9 +9,9 @@ # regenerated. # -------------------------------------------------------------------------- +import uuid from msrest.pipeline import ClientRawResponse from msrestazure.azure_exceptions import CloudError -import uuid from .. import models @@ -60,10 +60,13 @@ def create_or_update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`TrustedIdProvider + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`TrustedIdProvider - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ parameters = models.TrustedIdProvider(name=name, id_provider=id_provider) @@ -137,10 +140,13 @@ def update( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`TrustedIdProvider + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`TrustedIdProvider - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ parameters = None @@ -217,9 +223,11 @@ def delete( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :rtype: None - :rtype: :class:`ClientRawResponse` - if raw=true + :return: None or + :class:`ClientRawResponse` if + raw=true + :rtype: None or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -277,10 +285,13 @@ def get( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: :class:`TrustedIdProvider + ` or + :class:`ClientRawResponse` if + raw=true :rtype: :class:`TrustedIdProvider - ` - :rtype: :class:`ClientRawResponse` - if raw=true + ` or + :class:`ClientRawResponse` :raises: :class:`CloudError` """ # Construct URL @@ -343,6 +354,8 @@ def list_by_account( deserialized response :param operation_config: :ref:`Operation configuration overrides`. + :return: An iterator like instance of :class:`TrustedIdProvider + ` :rtype: :class:`TrustedIdProviderPaged ` :raises: :class:`CloudError`