Skip to content

Commit cb5aec2

Browse files
author
SDKAuto
committed
CodeGen from PR 24394 in Azure/azure-rest-api-specs
Merge fbc0af14bdd1cdc4ecbb176a7b8bbd70453d7eb2 into 1b33e81bbdc28fcd6644a1315b8d7b1b6d030590
1 parent ca0105e commit cb5aec2

File tree

67 files changed

+4526
-697
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+4526
-697
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"commit": "be6cd9ccfcb6ba08c1c206627026eabfbff31fc1",
2+
"commit": "4d03e7120630f8f9134f66b85d31952449a96eea",
33
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
44
"autorest": "3.9.2",
55
"use": [
6-
"@autorest/python@6.2.7",
6+
"@autorest/python@6.5.0",
77
"@autorest/[email protected]"
88
],
9-
"autorest_command": "autorest specification/azurearcdata/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.2.7 --use=@autorest/[email protected] --version=3.9.2 --version-tolerant=False",
9+
"autorest_command": "autorest specification/azurearcdata/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.5.0 --use=@autorest/[email protected] --version=3.9.2 --version-tolerant=False",
1010
"readme": "specification/azurearcdata/resource-manager/readme.md"
1111
}

sdk/azurearcdata/azure-mgmt-azurearcdata/azure/mgmt/azurearcdata/_azure_arc_data_management_client.py

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,11 @@
1818
from .operations import (
1919
ActiveDirectoryConnectorsOperations,
2020
DataControllersOperations,
21+
FailoverGroupsOperations,
2122
Operations,
2223
PostgresInstancesOperations,
2324
SqlManagedInstancesOperations,
25+
SqlServerDatabasesOperations,
2426
SqlServerInstancesOperations,
2527
)
2628

@@ -29,7 +31,7 @@
2931
from azure.core.credentials import TokenCredential
3032

3133

32-
class AzureArcDataManagementClient: # pylint: disable=client-accepts-api-version-keyword
34+
class AzureArcDataManagementClient: # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes
3335
"""The AzureArcData management API provides a RESTful set of web APIs to manage Azure Data
3436
Services on Azure Arc Resources.
3537
@@ -38,6 +40,8 @@ class AzureArcDataManagementClient: # pylint: disable=client-accepts-api-versio
3840
:ivar sql_managed_instances: SqlManagedInstancesOperations operations
3941
:vartype sql_managed_instances:
4042
azure.mgmt.azurearcdata.operations.SqlManagedInstancesOperations
43+
:ivar failover_groups: FailoverGroupsOperations operations
44+
:vartype failover_groups: azure.mgmt.azurearcdata.operations.FailoverGroupsOperations
4145
:ivar sql_server_instances: SqlServerInstancesOperations operations
4246
:vartype sql_server_instances: azure.mgmt.azurearcdata.operations.SqlServerInstancesOperations
4347
:ivar data_controllers: DataControllersOperations operations
@@ -47,13 +51,15 @@ class AzureArcDataManagementClient: # pylint: disable=client-accepts-api-versio
4751
azure.mgmt.azurearcdata.operations.ActiveDirectoryConnectorsOperations
4852
:ivar postgres_instances: PostgresInstancesOperations operations
4953
:vartype postgres_instances: azure.mgmt.azurearcdata.operations.PostgresInstancesOperations
54+
:ivar sql_server_databases: SqlServerDatabasesOperations operations
55+
:vartype sql_server_databases: azure.mgmt.azurearcdata.operations.SqlServerDatabasesOperations
5056
:param credential: Credential needed for the client to connect to Azure. Required.
5157
:type credential: ~azure.core.credentials.TokenCredential
5258
:param subscription_id: The ID of the Azure subscription. Required.
5359
:type subscription_id: str
5460
:param base_url: Service URL. Default value is "https://management.azure.com".
5561
:type base_url: str
56-
:keyword api_version: Api Version. Default value is "2022-03-01-preview". Note that overriding
62+
:keyword api_version: Api Version. Default value is "2023-01-15-preview". Note that overriding
5763
this default value may result in unsupported behavior.
5864
:paramtype api_version: str
5965
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
@@ -70,7 +76,7 @@ def __init__(
7076
self._config = AzureArcDataManagementClientConfiguration(
7177
credential=credential, subscription_id=subscription_id, **kwargs
7278
)
73-
self._client = ARMPipelineClient(base_url=base_url, config=self._config, **kwargs)
79+
self._client: ARMPipelineClient = ARMPipelineClient(base_url=base_url, config=self._config, **kwargs)
7480

7581
client_models = {k: v for k, v in _models.__dict__.items() if isinstance(v, type)}
7682
self._serialize = Serializer(client_models)
@@ -80,6 +86,7 @@ def __init__(
8086
self.sql_managed_instances = SqlManagedInstancesOperations(
8187
self._client, self._config, self._serialize, self._deserialize
8288
)
89+
self.failover_groups = FailoverGroupsOperations(self._client, self._config, self._serialize, self._deserialize)
8390
self.sql_server_instances = SqlServerInstancesOperations(
8491
self._client, self._config, self._serialize, self._deserialize
8592
)
@@ -92,6 +99,9 @@ def __init__(
9299
self.postgres_instances = PostgresInstancesOperations(
93100
self._client, self._config, self._serialize, self._deserialize
94101
)
102+
self.sql_server_databases = SqlServerDatabasesOperations(
103+
self._client, self._config, self._serialize, self._deserialize
104+
)
95105

96106
def _send_request(self, request: HttpRequest, **kwargs: Any) -> HttpResponse:
97107
"""Runs the network request through the client's chained policies.
@@ -122,5 +132,5 @@ def __enter__(self) -> "AzureArcDataManagementClient":
122132
self._client.__enter__()
123133
return self
124134

125-
def __exit__(self, *exc_details) -> None:
135+
def __exit__(self, *exc_details: Any) -> None:
126136
self._client.__exit__(*exc_details)

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

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
77
# --------------------------------------------------------------------------
88

9-
import sys
109
from typing import Any, TYPE_CHECKING
1110

1211
from azure.core.configuration import Configuration
@@ -15,11 +14,6 @@
1514

1615
from ._version import VERSION
1716

18-
if sys.version_info >= (3, 8):
19-
from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports
20-
else:
21-
from typing_extensions import Literal # type: ignore # pylint: disable=ungrouped-imports
22-
2317
if TYPE_CHECKING:
2418
# pylint: disable=unused-import,ungrouped-imports
2519
from azure.core.credentials import TokenCredential
@@ -35,14 +29,14 @@ class AzureArcDataManagementClientConfiguration(Configuration): # pylint: disab
3529
:type credential: ~azure.core.credentials.TokenCredential
3630
:param subscription_id: The ID of the Azure subscription. Required.
3731
:type subscription_id: str
38-
:keyword api_version: Api Version. Default value is "2022-03-01-preview". Note that overriding
32+
:keyword api_version: Api Version. Default value is "2023-01-15-preview". Note that overriding
3933
this default value may result in unsupported behavior.
4034
:paramtype api_version: str
4135
"""
4236

4337
def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None:
4438
super(AzureArcDataManagementClientConfiguration, self).__init__(**kwargs)
45-
api_version: Literal["2022-03-01-preview"] = kwargs.pop("api_version", "2022-03-01-preview")
39+
api_version: str = kwargs.pop("api_version", "2023-01-15-preview")
4640

4741
if credential is None:
4842
raise ValueError("Parameter 'credential' must not be None.")

0 commit comments

Comments
 (0)