Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions sdk/databox/azure-mgmt-databox/_meta.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"commit": "6e70667577cfb7bc194785683ca591b95abd524c",
"commit": "5d31f53fbd070705e63e349221d291df3c33ac10",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest": "3.9.2",
"autorest": "3.9.6",
"use": [
"@autorest/python@6.4.8",
"@autorest/modelerfour@4.24.3"
"@autorest/python@6.6.0",
"@autorest/modelerfour@4.26.2"
],
"autorest_command": "autorest specification/databox/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --use=@autorest/python@6.4.8 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False",
"autorest_command": "autorest specification/databox/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-python/sdk --use=@autorest/python@6.6.0 --use=@autorest/modelerfour@4.26.2 --version=3.9.6 --version-tolerant=False",
"readme": "specification/databox/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class DataBoxManagementClient(DataBoxManagementClientOperationsMixin, MultiApiCl
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
"""

DEFAULT_API_VERSION = '2022-12-01'
DEFAULT_API_VERSION = '2023-03-01'
_PROFILE_TAG = "azure.mgmt.databox.DataBoxManagementClient"
LATEST_PROFILE = ProfileDefinition({
_PROFILE_TAG: {
Expand All @@ -72,6 +72,8 @@ def __init__(
profile: KnownProfiles=KnownProfiles.default,
**kwargs: Any
):
if api_version:
kwargs.setdefault('api_version', api_version)
self._config = DataBoxManagementClientConfiguration(credential, subscription_id, **kwargs)
self._client = ARMPipelineClient(base_url=base_url, config=self._config, **kwargs)
super(DataBoxManagementClient, self).__init__(
Expand Down Expand Up @@ -99,6 +101,7 @@ def models(cls, api_version=DEFAULT_API_VERSION):
* 2022-09-01: :mod:`v2022_09_01.models<azure.mgmt.databox.v2022_09_01.models>`
* 2022-10-01: :mod:`v2022_10_01.models<azure.mgmt.databox.v2022_10_01.models>`
* 2022-12-01: :mod:`v2022_12_01.models<azure.mgmt.databox.v2022_12_01.models>`
* 2023-03-01: :mod:`v2023_03_01.models<azure.mgmt.databox.v2023_03_01.models>`
"""
if api_version == '2018-01-01':
from .v2018_01_01 import models
Expand Down Expand Up @@ -136,6 +139,9 @@ def models(cls, api_version=DEFAULT_API_VERSION):
elif api_version == '2022-12-01':
from .v2022_12_01 import models
return models
elif api_version == '2023-03-01':
from .v2023_03_01 import models
return models
raise ValueError("API version {} is not available".format(api_version))

@property
Expand All @@ -154,6 +160,7 @@ def jobs(self):
* 2022-09-01: :class:`JobsOperations<azure.mgmt.databox.v2022_09_01.operations.JobsOperations>`
* 2022-10-01: :class:`JobsOperations<azure.mgmt.databox.v2022_10_01.operations.JobsOperations>`
* 2022-12-01: :class:`JobsOperations<azure.mgmt.databox.v2022_12_01.operations.JobsOperations>`
* 2023-03-01: :class:`JobsOperations<azure.mgmt.databox.v2023_03_01.operations.JobsOperations>`
"""
api_version = self._get_api_version('jobs')
if api_version == '2018-01-01':
Expand All @@ -180,10 +187,12 @@ def jobs(self):
from .v2022_10_01.operations import JobsOperations as OperationClass
elif api_version == '2022-12-01':
from .v2022_12_01.operations import JobsOperations as OperationClass
elif api_version == '2023-03-01':
from .v2023_03_01.operations import JobsOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'jobs'".format(api_version))
self._config.api_version = api_version
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)

@property
def operations(self):
Expand All @@ -201,6 +210,7 @@ def operations(self):
* 2022-09-01: :class:`Operations<azure.mgmt.databox.v2022_09_01.operations.Operations>`
* 2022-10-01: :class:`Operations<azure.mgmt.databox.v2022_10_01.operations.Operations>`
* 2022-12-01: :class:`Operations<azure.mgmt.databox.v2022_12_01.operations.Operations>`
* 2023-03-01: :class:`Operations<azure.mgmt.databox.v2023_03_01.operations.Operations>`
"""
api_version = self._get_api_version('operations')
if api_version == '2018-01-01':
Expand All @@ -227,10 +237,12 @@ def operations(self):
from .v2022_10_01.operations import Operations as OperationClass
elif api_version == '2022-12-01':
from .v2022_12_01.operations import Operations as OperationClass
elif api_version == '2023-03-01':
from .v2023_03_01.operations import Operations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'operations'".format(api_version))
self._config.api_version = api_version
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)

@property
def service(self):
Expand All @@ -248,6 +260,7 @@ def service(self):
* 2022-09-01: :class:`ServiceOperations<azure.mgmt.databox.v2022_09_01.operations.ServiceOperations>`
* 2022-10-01: :class:`ServiceOperations<azure.mgmt.databox.v2022_10_01.operations.ServiceOperations>`
* 2022-12-01: :class:`ServiceOperations<azure.mgmt.databox.v2022_12_01.operations.ServiceOperations>`
* 2023-03-01: :class:`ServiceOperations<azure.mgmt.databox.v2023_03_01.operations.ServiceOperations>`
"""
api_version = self._get_api_version('service')
if api_version == '2018-01-01':
Expand All @@ -274,10 +287,12 @@ def service(self):
from .v2022_10_01.operations import ServiceOperations as OperationClass
elif api_version == '2022-12-01':
from .v2022_12_01.operations import ServiceOperations as OperationClass
elif api_version == '2023-03-01':
from .v2023_03_01.operations import ServiceOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'service'".format(api_version))
self._config.api_version = api_version
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)

def close(self):
self._client.close()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------
from ._serialization import Serializer, Deserializer
from io import IOBase
from typing import Any, IO, Optional, Union

from . import models as _models
Expand All @@ -33,7 +34,7 @@ def mitigate( # pylint: disable=inconsistent-return-statements
:type resource_group_name: str
:param mitigate_job_request: Mitigation Request. Is either a MitigateJobRequest type or a IO
type. Required.
:type mitigate_job_request: ~azure.mgmt.databox.v2022_12_01.models.MitigateJobRequest or IO
:type mitigate_job_request: ~azure.mgmt.databox.v2023_03_01.models.MitigateJobRequest or IO
:keyword content_type: Body Parameter content-type. Known values are: 'application/json'.
Default value is None.
:paramtype content_type: str
Expand All @@ -59,6 +60,8 @@ def mitigate( # pylint: disable=inconsistent-return-statements
from .v2022_10_01.operations import DataBoxManagementClientOperationsMixin as OperationClass
elif api_version == '2022-12-01':
from .v2022_12_01.operations import DataBoxManagementClientOperationsMixin as OperationClass
elif api_version == '2023-03-01':
from .v2023_03_01.operations import DataBoxManagementClientOperationsMixin as OperationClass
else:
raise ValueError("API version {} does not have operation 'mitigate'".format(api_version))
mixin_instance = OperationClass()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
# license information.
# --------------------------------------------------------------------------

VERSION = "2.0.0"
VERSION = "0.1.0"
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class DataBoxManagementClient(DataBoxManagementClientOperationsMixin, MultiApiCl
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
"""

DEFAULT_API_VERSION = '2022-12-01'
DEFAULT_API_VERSION = '2023-03-01'
_PROFILE_TAG = "azure.mgmt.databox.DataBoxManagementClient"
LATEST_PROFILE = ProfileDefinition({
_PROFILE_TAG: {
Expand All @@ -72,6 +72,8 @@ def __init__(
profile: KnownProfiles = KnownProfiles.default,
**kwargs: Any
) -> None:
if api_version:
kwargs.setdefault('api_version', api_version)
self._config = DataBoxManagementClientConfiguration(credential, subscription_id, **kwargs)
self._client = AsyncARMPipelineClient(base_url=base_url, config=self._config, **kwargs)
super(DataBoxManagementClient, self).__init__(
Expand Down Expand Up @@ -99,6 +101,7 @@ def models(cls, api_version=DEFAULT_API_VERSION):
* 2022-09-01: :mod:`v2022_09_01.models<azure.mgmt.databox.v2022_09_01.models>`
* 2022-10-01: :mod:`v2022_10_01.models<azure.mgmt.databox.v2022_10_01.models>`
* 2022-12-01: :mod:`v2022_12_01.models<azure.mgmt.databox.v2022_12_01.models>`
* 2023-03-01: :mod:`v2023_03_01.models<azure.mgmt.databox.v2023_03_01.models>`
"""
if api_version == '2018-01-01':
from ..v2018_01_01 import models
Expand Down Expand Up @@ -136,6 +139,9 @@ def models(cls, api_version=DEFAULT_API_VERSION):
elif api_version == '2022-12-01':
from ..v2022_12_01 import models
return models
elif api_version == '2023-03-01':
from ..v2023_03_01 import models
return models
raise ValueError("API version {} is not available".format(api_version))

@property
Expand All @@ -154,6 +160,7 @@ def jobs(self):
* 2022-09-01: :class:`JobsOperations<azure.mgmt.databox.v2022_09_01.aio.operations.JobsOperations>`
* 2022-10-01: :class:`JobsOperations<azure.mgmt.databox.v2022_10_01.aio.operations.JobsOperations>`
* 2022-12-01: :class:`JobsOperations<azure.mgmt.databox.v2022_12_01.aio.operations.JobsOperations>`
* 2023-03-01: :class:`JobsOperations<azure.mgmt.databox.v2023_03_01.aio.operations.JobsOperations>`
"""
api_version = self._get_api_version('jobs')
if api_version == '2018-01-01':
Expand All @@ -180,10 +187,12 @@ def jobs(self):
from ..v2022_10_01.aio.operations import JobsOperations as OperationClass
elif api_version == '2022-12-01':
from ..v2022_12_01.aio.operations import JobsOperations as OperationClass
elif api_version == '2023-03-01':
from ..v2023_03_01.aio.operations import JobsOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'jobs'".format(api_version))
self._config.api_version = api_version
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)

@property
def operations(self):
Expand All @@ -201,6 +210,7 @@ def operations(self):
* 2022-09-01: :class:`Operations<azure.mgmt.databox.v2022_09_01.aio.operations.Operations>`
* 2022-10-01: :class:`Operations<azure.mgmt.databox.v2022_10_01.aio.operations.Operations>`
* 2022-12-01: :class:`Operations<azure.mgmt.databox.v2022_12_01.aio.operations.Operations>`
* 2023-03-01: :class:`Operations<azure.mgmt.databox.v2023_03_01.aio.operations.Operations>`
"""
api_version = self._get_api_version('operations')
if api_version == '2018-01-01':
Expand All @@ -227,10 +237,12 @@ def operations(self):
from ..v2022_10_01.aio.operations import Operations as OperationClass
elif api_version == '2022-12-01':
from ..v2022_12_01.aio.operations import Operations as OperationClass
elif api_version == '2023-03-01':
from ..v2023_03_01.aio.operations import Operations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'operations'".format(api_version))
self._config.api_version = api_version
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)

@property
def service(self):
Expand All @@ -248,6 +260,7 @@ def service(self):
* 2022-09-01: :class:`ServiceOperations<azure.mgmt.databox.v2022_09_01.aio.operations.ServiceOperations>`
* 2022-10-01: :class:`ServiceOperations<azure.mgmt.databox.v2022_10_01.aio.operations.ServiceOperations>`
* 2022-12-01: :class:`ServiceOperations<azure.mgmt.databox.v2022_12_01.aio.operations.ServiceOperations>`
* 2023-03-01: :class:`ServiceOperations<azure.mgmt.databox.v2023_03_01.aio.operations.ServiceOperations>`
"""
api_version = self._get_api_version('service')
if api_version == '2018-01-01':
Expand All @@ -274,10 +287,12 @@ def service(self):
from ..v2022_10_01.aio.operations import ServiceOperations as OperationClass
elif api_version == '2022-12-01':
from ..v2022_12_01.aio.operations import ServiceOperations as OperationClass
elif api_version == '2023-03-01':
from ..v2023_03_01.aio.operations import ServiceOperations as OperationClass
else:
raise ValueError("API version {} does not have operation group 'service'".format(api_version))
self._config.api_version = api_version
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)

async def close(self):
await self._client.close()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
# regenerated.
# --------------------------------------------------------------------------
from .._serialization import Serializer, Deserializer
from io import IOBase
from typing import Any, IO, Optional, Union

from .. import models as _models
Expand All @@ -33,7 +34,7 @@ async def mitigate( # pylint: disable=inconsistent-return-statements
:type resource_group_name: str
:param mitigate_job_request: Mitigation Request. Is either a MitigateJobRequest type or a IO
type. Required.
:type mitigate_job_request: ~azure.mgmt.databox.v2022_12_01.models.MitigateJobRequest or IO
:type mitigate_job_request: ~azure.mgmt.databox.v2023_03_01.models.MitigateJobRequest or IO
:keyword content_type: Body Parameter content-type. Known values are: 'application/json'.
Default value is None.
:paramtype content_type: str
Expand All @@ -59,6 +60,8 @@ async def mitigate( # pylint: disable=inconsistent-return-statements
from ..v2022_10_01.aio.operations import DataBoxManagementClientOperationsMixin as OperationClass
elif api_version == '2022-12-01':
from ..v2022_12_01.aio.operations import DataBoxManagementClientOperationsMixin as OperationClass
elif api_version == '2023-03-01':
from ..v2023_03_01.aio.operations import DataBoxManagementClientOperationsMixin as OperationClass
else:
raise ValueError("API version {} does not have operation 'mitigate'".format(api_version))
mixin_instance = OperationClass()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
# Licensed under the MIT License. See License.txt in the project root for
# license information.
# --------------------------------------------------------------------------
from .v2022_12_01.models import *
from .v2023_03_01.models import *
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ def __init__(
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)
self._serialize.client_side_validation = False
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
self.jobs = JobsOperations(self._client, self._config, self._serialize, self._deserialize)
self.service = ServiceOperations(self._client, self._config, self._serialize, self._deserialize)
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize, "2018-01-01")
self.jobs = JobsOperations(self._client, self._config, self._serialize, self._deserialize, "2018-01-01")
self.service = ServiceOperations(self._client, self._config, self._serialize, self._deserialize, "2018-01-01")

def _send_request(self, request: HttpRequest, **kwargs: Any) -> HttpResponse:
"""Runs the network request through the client's chained policies.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

VERSION = "2.0.0"
VERSION = "1.0.0b1"
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ def __init__(
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)
self._serialize.client_side_validation = False
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
self.jobs = JobsOperations(self._client, self._config, self._serialize, self._deserialize)
self.service = ServiceOperations(self._client, self._config, self._serialize, self._deserialize)
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize, "2018-01-01")
self.jobs = JobsOperations(self._client, self._config, self._serialize, self._deserialize, "2018-01-01")
self.service = ServiceOperations(self._client, self._config, self._serialize, self._deserialize, "2018-01-01")

def _send_request(self, request: HttpRequest, **kwargs: Any) -> Awaitable[AsyncHttpResponse]:
"""Runs the network request through the client's chained policies.
Expand Down
Loading