Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR] storage/resource-manager #7446

Merged
merged 10 commits into from
Sep 29, 2019
10 changes: 10 additions & 0 deletions sdk/storage/azure-mgmt-storage/HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,16 @@
Release History
===============

4.1.0 (2019-09-27)
++++++++++++++++++

**Features**

- Model BlobServiceProperties has a new parameter change_feed
- Added operation BlobServicesOperations.list
- Added operation group FileServicesOperations
- Added operation group FileSharesOperations

4.0.0 (2019-06-12)
++++++++++++++++++

Expand Down
2 changes: 1 addition & 1 deletion sdk/storage/azure-mgmt-storage/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This is the Microsoft Azure Storage Management Client Library.
Azure Resource Manager (ARM) is the next generation of management APIs that
replace the old Azure Service Management (ASM).

This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7.
This package has been tested with Python 2.7, 3.5, 3.6 and 3.7.

For the older Azure Service Management (ASM) libraries, see
`azure-servicemanagement-legacy <https://pypi.python.org/pypi/azure-servicemanagement-legacy>`__ library.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

from azure.profiles import KnownProfiles, ProfileDefinition
from azure.profiles.multiapiclient import MultiApiClientMixin
from .version import VERSION
from ._configuration import StorageManagementClientConfiguration


Expand Down Expand Up @@ -51,8 +50,8 @@ class StorageManagementClient(MultiApiClientMixin, SDKClient):
_PROFILE_TAG = "azure.mgmt.storage.StorageManagementClient"
LATEST_PROFILE = ProfileDefinition({
_PROFILE_TAG: {
None: DEFAULT_API_VERSION,
'usage': '2018-02-01',
None: DEFAULT_API_VERSION
}},
_PROFILE_TAG + " latest"
)
Expand Down Expand Up @@ -161,6 +160,32 @@ def blob_services(self):
raise NotImplementedError("APIVersion {} is not available".format(api_version))
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

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

* 2019-04-01: :class:`FileServicesOperations<azure.mgmt.storage.v2019_04_01.operations.FileServicesOperations>`
"""
api_version = self._get_api_version('file_services')
if api_version == '2019-04-01':
from .v2019_04_01.operations import FileServicesOperations as OperationClass
else:
raise NotImplementedError("APIVersion {} is not available".format(api_version))
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

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

* 2019-04-01: :class:`FileSharesOperations<azure.mgmt.storage.v2019_04_01.operations.FileSharesOperations>`
"""
api_version = self._get_api_version('file_shares')
if api_version == '2019-04-01':
from .v2019_04_01.operations import FileSharesOperations as OperationClass
else:
raise NotImplementedError("APIVersion {} is not available".format(api_version))
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

@property
def management_policies(self):
"""Instance depends on the API version:
Expand Down
8 changes: 0 additions & 8 deletions sdk/storage/azure-mgmt-storage/azure/mgmt/storage/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,5 @@
# Licensed under the MIT License. See License.txt in the project root for
# license information.
# --------------------------------------------------------------------------
from .v2015_06_15.models import *
from .v2016_01_01.models import *
from .v2016_12_01.models import *
from .v2017_06_01.models import *
from .v2017_10_01.models import *
from .v2018_02_01.models import *
from .v2018_03_01_preview.models import *
from .v2018_07_01.models import *
from .v2018_11_01.models import *
from .v2019_04_01.models import *
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
from .operations import ManagementPoliciesOperations
from .operations import BlobServicesOperations
from .operations import BlobContainersOperations
from .operations import FileServicesOperations
from .operations import FileSharesOperations
from . import models


Expand All @@ -43,6 +45,10 @@ class StorageManagementClient(SDKClient):
:vartype blob_services: azure.mgmt.storage.v2019_04_01.operations.BlobServicesOperations
:ivar blob_containers: BlobContainers operations
:vartype blob_containers: azure.mgmt.storage.v2019_04_01.operations.BlobContainersOperations
:ivar file_services: FileServices operations
:vartype file_services: azure.mgmt.storage.v2019_04_01.operations.FileServicesOperations
:ivar file_shares: FileShares operations
:vartype file_shares: azure.mgmt.storage.v2019_04_01.operations.FileSharesOperations

:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
Expand Down Expand Up @@ -77,3 +83,7 @@ def __init__(
self._client, self.config, self._serialize, self._deserialize)
self.blob_containers = BlobContainersOperations(
self._client, self.config, self._serialize, self._deserialize)
self.file_services = FileServicesOperations(
self._client, self.config, self._serialize, self._deserialize)
self.file_shares = FileSharesOperations(
self._client, self.config, self._serialize, self._deserialize)
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
from ._models_py3 import AzureFilesIdentityBasedAuthentication
from ._models_py3 import BlobContainer
from ._models_py3 import BlobServiceProperties
from ._models_py3 import ChangeFeed
from ._models_py3 import CheckNameAvailabilityResult
from ._models_py3 import CorsRule
from ._models_py3 import CorsRules
Expand All @@ -27,6 +28,10 @@
from ._models_py3 import EncryptionService
from ._models_py3 import EncryptionServices
from ._models_py3 import Endpoints
from ._models_py3 import FileServiceItems
from ._models_py3 import FileServiceProperties
from ._models_py3 import FileShare
from ._models_py3 import FileShareItem
from ._models_py3 import GeoReplicationStats
from ._models_py3 import Identity
from ._models_py3 import ImmutabilityPolicy
Expand Down Expand Up @@ -78,6 +83,7 @@
from ._models import AzureFilesIdentityBasedAuthentication
from ._models import BlobContainer
from ._models import BlobServiceProperties
from ._models import ChangeFeed
from ._models import CheckNameAvailabilityResult
from ._models import CorsRule
from ._models import CorsRules
Expand All @@ -90,6 +96,10 @@
from ._models import EncryptionService
from ._models import EncryptionServices
from ._models import Endpoints
from ._models import FileServiceItems
from ._models import FileServiceProperties
from ._models import FileShare
from ._models import FileShareItem
from ._models import GeoReplicationStats
from ._models import Identity
from ._models import ImmutabilityPolicy
Expand Down Expand Up @@ -135,6 +145,8 @@
from ._models import Usage
from ._models import UsageName
from ._models import VirtualNetworkRule
from ._paged_models import BlobServicePropertiesPaged
from ._paged_models import FileShareItemPaged
from ._paged_models import ListContainerItemPaged
from ._paged_models import OperationPaged
from ._paged_models import SkuPaged
Expand Down Expand Up @@ -178,6 +190,7 @@
'AzureFilesIdentityBasedAuthentication',
'BlobContainer',
'BlobServiceProperties',
'ChangeFeed',
'CheckNameAvailabilityResult',
'CorsRule',
'CorsRules',
Expand All @@ -190,6 +203,10 @@
'EncryptionService',
'EncryptionServices',
'Endpoints',
'FileServiceItems',
'FileServiceProperties',
'FileShare',
'FileShareItem',
'GeoReplicationStats',
'Identity',
'ImmutabilityPolicy',
Expand Down Expand Up @@ -239,7 +256,9 @@
'SkuPaged',
'StorageAccountPaged',
'UsagePaged',
'BlobServicePropertiesPaged',
'ListContainerItemPaged',
'FileShareItemPaged',
'ReasonCode',
'SkuName',
'SkuTier',
Expand Down
Loading