Skip to content

Commit 5851ccf

Browse files
author
SDKAuto
committed
CodeGen from PR 13540 in Azure/azure-rest-api-specs
Merge 53cabcef924ebaa71dff9c43b3696c2b1ce56668 into e1b647a
1 parent 58c46ee commit 5851ccf

20 files changed

+541
-353
lines changed

sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/__init__.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@
77
# --------------------------------------------------------------------------
88

99
from ._microsoft_datadog_client import MicrosoftDatadogClient
10-
from ._version import VERSION
11-
12-
__version__ = VERSION
1310
__all__ = ['MicrosoftDatadogClient']
1411

1512
try:

sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/_configuration.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,13 @@
1212
from azure.core.pipeline import policies
1313
from azure.mgmt.core.policies import ARMHttpLoggingPolicy
1414

15-
from ._version import VERSION
16-
1715
if TYPE_CHECKING:
1816
# pylint: disable=unused-import,ungrouped-imports
1917
from typing import Any
2018

2119
from azure.core.credentials import TokenCredential
2220

21+
VERSION = "unknown"
2322

2423
class MicrosoftDatadogClientConfiguration(Configuration):
2524
"""Configuration for MicrosoftDatadogClient.
@@ -29,7 +28,7 @@ class MicrosoftDatadogClientConfiguration(Configuration):
2928
3029
:param credential: Credential needed for the client to connect to Azure.
3130
:type credential: ~azure.core.credentials.TokenCredential
32-
:param subscription_id: The Microsoft Azure subscription ID.
31+
:param subscription_id: The ID of the target subscription.
3332
:type subscription_id: str
3433
"""
3534

@@ -48,7 +47,7 @@ def __init__(
4847

4948
self.credential = credential
5049
self.subscription_id = subscription_id
51-
self.api_version = "2020-02-01-preview"
50+
self.api_version = "2021-03-01"
5251
self.credential_scopes = kwargs.pop('credential_scopes', ['https://management.azure.com/.default'])
5352
kwargs.setdefault('sdk_moniker', 'mgmt-datadog/{}'.format(VERSION))
5453
self._configure(**kwargs)

sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/_metadata.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"chosen_version": "2020-02-01-preview",
3-
"total_api_version_list": ["2020-02-01-preview"],
2+
"chosen_version": "2021-03-01",
3+
"total_api_version_list": ["2021-03-01"],
44
"client": {
55
"name": "MicrosoftDatadogClient",
66
"filename": "_microsoft_datadog_client",
@@ -21,7 +21,7 @@
2121
},
2222
"subscription_id": {
2323
"signature": "subscription_id, # type: str",
24-
"description": "The Microsoft Azure subscription ID.",
24+
"description": "The ID of the target subscription.",
2525
"docstring_type": "str",
2626
"required": true
2727
}
@@ -35,7 +35,7 @@
3535
},
3636
"subscription_id": {
3737
"signature": "subscription_id, # type: str",
38-
"description": "The Microsoft Azure subscription ID.",
38+
"description": "The ID of the target subscription.",
3939
"docstring_type": "str",
4040
"required": true
4141
}

sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/_microsoft_datadog_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class MicrosoftDatadogClient(object):
4141
:vartype single_sign_on_configurations: microsoft_datadog_client.operations.SingleSignOnConfigurationsOperations
4242
:param credential: Credential needed for the client to connect to Azure.
4343
:type credential: ~azure.core.credentials.TokenCredential
44-
:param subscription_id: The Microsoft Azure subscription ID.
44+
:param subscription_id: The ID of the target subscription.
4545
:type subscription_id: str
4646
:param str base_url: Service URL
4747
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.

sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/aio/_configuration.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,11 @@
1212
from azure.core.pipeline import policies
1313
from azure.mgmt.core.policies import ARMHttpLoggingPolicy
1414

15-
from .._version import VERSION
16-
1715
if TYPE_CHECKING:
1816
# pylint: disable=unused-import,ungrouped-imports
1917
from azure.core.credentials_async import AsyncTokenCredential
2018

19+
VERSION = "unknown"
2120

2221
class MicrosoftDatadogClientConfiguration(Configuration):
2322
"""Configuration for MicrosoftDatadogClient.
@@ -27,7 +26,7 @@ class MicrosoftDatadogClientConfiguration(Configuration):
2726
2827
:param credential: Credential needed for the client to connect to Azure.
2928
:type credential: ~azure.core.credentials_async.AsyncTokenCredential
30-
:param subscription_id: The Microsoft Azure subscription ID.
29+
:param subscription_id: The ID of the target subscription.
3130
:type subscription_id: str
3231
"""
3332

@@ -45,7 +44,7 @@ def __init__(
4544

4645
self.credential = credential
4746
self.subscription_id = subscription_id
48-
self.api_version = "2020-02-01-preview"
47+
self.api_version = "2021-03-01"
4948
self.credential_scopes = kwargs.pop('credential_scopes', ['https://management.azure.com/.default'])
5049
kwargs.setdefault('sdk_moniker', 'mgmt-datadog/{}'.format(VERSION))
5150
self._configure(**kwargs)

sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/aio/_microsoft_datadog_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class MicrosoftDatadogClient(object):
3939
:vartype single_sign_on_configurations: microsoft_datadog_client.aio.operations.SingleSignOnConfigurationsOperations
4040
:param credential: Credential needed for the client to connect to Azure.
4141
:type credential: ~azure.core.credentials_async.AsyncTokenCredential
42-
:param subscription_id: The Microsoft Azure subscription ID.
42+
:param subscription_id: The ID of the target subscription.
4343
:type subscription_id: str
4444
:param str base_url: Service URL
4545
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.

sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/aio/operations/_marketplace_agreements_operations.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def list(
5959
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
6060
}
6161
error_map.update(kwargs.pop('error_map', {}))
62-
api_version = "2020-02-01-preview"
62+
api_version = "2021-03-01"
6363
accept = "application/json"
6464

6565
def prepare_request(next_link=None):
@@ -71,7 +71,7 @@ def prepare_request(next_link=None):
7171
# Construct URL
7272
url = self.list.metadata['url'] # type: ignore
7373
path_format_arguments = {
74-
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str'),
74+
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
7575
}
7676
url = self._client.format_url(url, **path_format_arguments)
7777
# Construct parameters
@@ -99,7 +99,7 @@ async def get_next(next_link=None):
9999
response = pipeline_response.http_response
100100

101101
if response.status_code not in [200]:
102-
error = self._deserialize(_models.ResourceProviderDefaultErrorResponse, response)
102+
error = self._deserialize(_models.ErrorResponse, response)
103103
map_error(status_code=response.status_code, response=response, error_map=error_map)
104104
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)
105105

@@ -131,14 +131,14 @@ async def create_or_update(
131131
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
132132
}
133133
error_map.update(kwargs.pop('error_map', {}))
134-
api_version = "2020-02-01-preview"
134+
api_version = "2021-03-01"
135135
content_type = kwargs.pop("content_type", "application/json")
136136
accept = "application/json"
137137

138138
# Construct URL
139139
url = self.create_or_update.metadata['url'] # type: ignore
140140
path_format_arguments = {
141-
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str'),
141+
'subscriptionId': self._serialize.url("self._config.subscription_id", self._config.subscription_id, 'str', min_length=1),
142142
}
143143
url = self._client.format_url(url, **path_format_arguments)
144144

@@ -163,7 +163,7 @@ async def create_or_update(
163163

164164
if response.status_code not in [200]:
165165
map_error(status_code=response.status_code, response=response, error_map=error_map)
166-
error = self._deserialize(_models.ResourceProviderDefaultErrorResponse, response)
166+
error = self._deserialize(_models.ErrorResponse, response)
167167
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)
168168

169169
deserialized = self._deserialize('DatadogAgreementResource', pipeline_response)

0 commit comments

Comments
 (0)