Skip to content

Commit 7e050d9

Browse files
[AutoRelease] t2-hybridcompute-2024-05-30-29871(can only be merged by SDK owner) (#35824)
* code and test * Update CHANGELOG.md * Update assets.json --------- Co-authored-by: azure-sdk <PythonSdkPipelines> Co-authored-by: ChenxiJiang333 <[email protected]> Co-authored-by: ChenxiJiang333 <[email protected]>
1 parent 4c85db2 commit 7e050d9

File tree

95 files changed

+6971
-218
lines changed

Some content is hidden

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

95 files changed

+6971
-218
lines changed

sdk/hybridcompute/azure-mgmt-hybridcompute/CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,16 @@
11
# Release History
22

3+
## 9.0.0b3 (2024-05-30)
4+
5+
### Features Added
6+
7+
- Added operation MachineRunCommandsOperations.begin_update
8+
- Added operation group GatewaysOperations
9+
- Added operation group LicensesOperations
10+
- Added operation group NetworkSecurityPerimeterConfigurationsOperations
11+
- Added operation group SettingsOperations
12+
- Model LicenseDetails has a new parameter volume_license_details
13+
314
## 9.0.0b2 (2024-04-22)
415

516
### Features Added
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"commit": "71a0c7adf2a6e169ab9a33c7cf36bb93db083e86",
2+
"commit": "34f8f3fa251276229e64680c29abe1d194559661",
33
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
4-
"autorest": "3.9.7",
4+
"autorest": "3.10.2",
55
"use": [
6-
"@autorest/[email protected].7",
6+
"@autorest/[email protected].16",
77
"@autorest/[email protected]"
88
],
9-
"autorest_command": "autorest specification/hybridcompute/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/[email protected].7 --use=@autorest/[email protected] --version=3.9.7 --version-tolerant=False",
9+
"autorest_command": "autorest specification/hybridcompute/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/[email protected].16 --use=@autorest/[email protected] --version=3.10.2 --version-tolerant=False",
1010
"readme": "specification/hybridcompute/resource-manager/readme.md"
1111
}

sdk/hybridcompute/azure-mgmt-hybridcompute/assets.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
"AssetsRepo": "Azure/azure-sdk-assets",
33
"AssetsRepoPrefixPath": "python",
44
"TagPrefix": "python/hybridcompute/azure-mgmt-hybridcompute",
5-
"Tag": "python/hybridcompute/azure-mgmt-hybridcompute_4737bbece7"
5+
"Tag": "python/hybridcompute/azure-mgmt-hybridcompute_c4b455e500"
66
}

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ class HybridComputeManagementClientConfiguration: # pylint: disable=too-many-in
2828
:type credential: ~azure.core.credentials.TokenCredential
2929
:param subscription_id: The ID of the target subscription. Required.
3030
:type subscription_id: str
31-
:keyword api_version: Api Version. Default value is "2023-10-03-preview". Note that overriding
31+
:keyword api_version: Api Version. Default value is "2024-03-31-preview". Note that overriding
3232
this default value may result in unsupported behavior.
3333
:paramtype api_version: str
3434
"""
3535

3636
def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None:
37-
api_version: str = kwargs.pop("api_version", "2023-10-03-preview")
37+
api_version: str = kwargs.pop("api_version", "2024-03-31-preview")
3838

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

sdk/hybridcompute/azure-mgmt-hybridcompute/azure/mgmt/hybridcompute/_hybrid_compute_management_client.py

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,19 @@
1919
from ._serialization import Deserializer, Serializer
2020
from .operations import (
2121
ExtensionMetadataOperations,
22+
GatewaysOperations,
2223
HybridComputeManagementClientOperationsMixin,
24+
LicensesOperations,
2325
MachineExtensionsOperations,
2426
MachineRunCommandsOperations,
2527
MachinesOperations,
2628
NetworkProfileOperations,
29+
NetworkSecurityPerimeterConfigurationsOperations,
2730
Operations,
2831
PrivateEndpointConnectionsOperations,
2932
PrivateLinkResourcesOperations,
3033
PrivateLinkScopesOperations,
34+
SettingsOperations,
3135
)
3236

3337
if TYPE_CHECKING:
@@ -40,6 +44,8 @@ class HybridComputeManagementClient(
4044
): # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes
4145
"""The Hybrid Compute Management Client.
4246
47+
:ivar licenses: LicensesOperations operations
48+
:vartype licenses: azure.mgmt.hybridcompute.operations.LicensesOperations
4349
:ivar machines: MachinesOperations operations
4450
:vartype machines: azure.mgmt.hybridcompute.operations.MachinesOperations
4551
:ivar machine_extensions: MachineExtensionsOperations operations
@@ -52,6 +58,10 @@ class HybridComputeManagementClient(
5258
:vartype network_profile: azure.mgmt.hybridcompute.operations.NetworkProfileOperations
5359
:ivar machine_run_commands: MachineRunCommandsOperations operations
5460
:vartype machine_run_commands: azure.mgmt.hybridcompute.operations.MachineRunCommandsOperations
61+
:ivar gateways: GatewaysOperations operations
62+
:vartype gateways: azure.mgmt.hybridcompute.operations.GatewaysOperations
63+
:ivar settings: SettingsOperations operations
64+
:vartype settings: azure.mgmt.hybridcompute.operations.SettingsOperations
5565
:ivar private_link_scopes: PrivateLinkScopesOperations operations
5666
:vartype private_link_scopes: azure.mgmt.hybridcompute.operations.PrivateLinkScopesOperations
5767
:ivar private_link_resources: PrivateLinkResourcesOperations operations
@@ -60,13 +70,17 @@ class HybridComputeManagementClient(
6070
:ivar private_endpoint_connections: PrivateEndpointConnectionsOperations operations
6171
:vartype private_endpoint_connections:
6272
azure.mgmt.hybridcompute.operations.PrivateEndpointConnectionsOperations
73+
:ivar network_security_perimeter_configurations:
74+
NetworkSecurityPerimeterConfigurationsOperations operations
75+
:vartype network_security_perimeter_configurations:
76+
azure.mgmt.hybridcompute.operations.NetworkSecurityPerimeterConfigurationsOperations
6377
:param credential: Credential needed for the client to connect to Azure. Required.
6478
:type credential: ~azure.core.credentials.TokenCredential
6579
:param subscription_id: The ID of the target subscription. Required.
6680
:type subscription_id: str
6781
:param base_url: Service URL. Default value is "https://management.azure.com".
6882
:type base_url: str
69-
:keyword api_version: Api Version. Default value is "2023-10-03-preview". Note that overriding
83+
:keyword api_version: Api Version. Default value is "2024-03-31-preview". Note that overriding
7084
this default value may result in unsupported behavior.
7185
:paramtype api_version: str
7286
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
@@ -107,6 +121,7 @@ def __init__(
107121
self._serialize = Serializer(client_models)
108122
self._deserialize = Deserializer(client_models)
109123
self._serialize.client_side_validation = False
124+
self.licenses = LicensesOperations(self._client, self._config, self._serialize, self._deserialize)
110125
self.machines = MachinesOperations(self._client, self._config, self._serialize, self._deserialize)
111126
self.machine_extensions = MachineExtensionsOperations(
112127
self._client, self._config, self._serialize, self._deserialize
@@ -119,6 +134,8 @@ def __init__(
119134
self.machine_run_commands = MachineRunCommandsOperations(
120135
self._client, self._config, self._serialize, self._deserialize
121136
)
137+
self.gateways = GatewaysOperations(self._client, self._config, self._serialize, self._deserialize)
138+
self.settings = SettingsOperations(self._client, self._config, self._serialize, self._deserialize)
122139
self.private_link_scopes = PrivateLinkScopesOperations(
123140
self._client, self._config, self._serialize, self._deserialize
124141
)
@@ -128,6 +145,9 @@ def __init__(
128145
self.private_endpoint_connections = PrivateEndpointConnectionsOperations(
129146
self._client, self._config, self._serialize, self._deserialize
130147
)
148+
self.network_security_perimeter_configurations = NetworkSecurityPerimeterConfigurationsOperations(
149+
self._client, self._config, self._serialize, self._deserialize
150+
)
131151

132152
def _send_request(self, request: HttpRequest, *, stream: bool = False, **kwargs: Any) -> HttpResponse:
133153
"""Runs the network request through the client's chained policies.

sdk/hybridcompute/azure-mgmt-hybridcompute/azure/mgmt/hybridcompute/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@
66
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
77
# --------------------------------------------------------------------------
88

9-
VERSION = "9.0.0b2"
9+
VERSION = "9.0.0b3"

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ class HybridComputeManagementClientConfiguration: # pylint: disable=too-many-in
2828
:type credential: ~azure.core.credentials_async.AsyncTokenCredential
2929
:param subscription_id: The ID of the target subscription. Required.
3030
:type subscription_id: str
31-
:keyword api_version: Api Version. Default value is "2023-10-03-preview". Note that overriding
31+
:keyword api_version: Api Version. Default value is "2024-03-31-preview". Note that overriding
3232
this default value may result in unsupported behavior.
3333
:paramtype api_version: str
3434
"""
3535

3636
def __init__(self, credential: "AsyncTokenCredential", subscription_id: str, **kwargs: Any) -> None:
37-
api_version: str = kwargs.pop("api_version", "2023-10-03-preview")
37+
api_version: str = kwargs.pop("api_version", "2024-03-31-preview")
3838

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

sdk/hybridcompute/azure-mgmt-hybridcompute/azure/mgmt/hybridcompute/aio/_hybrid_compute_management_client.py

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,19 @@
1919
from ._configuration import HybridComputeManagementClientConfiguration
2020
from .operations import (
2121
ExtensionMetadataOperations,
22+
GatewaysOperations,
2223
HybridComputeManagementClientOperationsMixin,
24+
LicensesOperations,
2325
MachineExtensionsOperations,
2426
MachineRunCommandsOperations,
2527
MachinesOperations,
2628
NetworkProfileOperations,
29+
NetworkSecurityPerimeterConfigurationsOperations,
2730
Operations,
2831
PrivateEndpointConnectionsOperations,
2932
PrivateLinkResourcesOperations,
3033
PrivateLinkScopesOperations,
34+
SettingsOperations,
3135
)
3236

3337
if TYPE_CHECKING:
@@ -40,6 +44,8 @@ class HybridComputeManagementClient(
4044
): # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes
4145
"""The Hybrid Compute Management Client.
4246
47+
:ivar licenses: LicensesOperations operations
48+
:vartype licenses: azure.mgmt.hybridcompute.aio.operations.LicensesOperations
4349
:ivar machines: MachinesOperations operations
4450
:vartype machines: azure.mgmt.hybridcompute.aio.operations.MachinesOperations
4551
:ivar machine_extensions: MachineExtensionsOperations operations
@@ -55,6 +61,10 @@ class HybridComputeManagementClient(
5561
:ivar machine_run_commands: MachineRunCommandsOperations operations
5662
:vartype machine_run_commands:
5763
azure.mgmt.hybridcompute.aio.operations.MachineRunCommandsOperations
64+
:ivar gateways: GatewaysOperations operations
65+
:vartype gateways: azure.mgmt.hybridcompute.aio.operations.GatewaysOperations
66+
:ivar settings: SettingsOperations operations
67+
:vartype settings: azure.mgmt.hybridcompute.aio.operations.SettingsOperations
5868
:ivar private_link_scopes: PrivateLinkScopesOperations operations
5969
:vartype private_link_scopes:
6070
azure.mgmt.hybridcompute.aio.operations.PrivateLinkScopesOperations
@@ -64,13 +74,17 @@ class HybridComputeManagementClient(
6474
:ivar private_endpoint_connections: PrivateEndpointConnectionsOperations operations
6575
:vartype private_endpoint_connections:
6676
azure.mgmt.hybridcompute.aio.operations.PrivateEndpointConnectionsOperations
77+
:ivar network_security_perimeter_configurations:
78+
NetworkSecurityPerimeterConfigurationsOperations operations
79+
:vartype network_security_perimeter_configurations:
80+
azure.mgmt.hybridcompute.aio.operations.NetworkSecurityPerimeterConfigurationsOperations
6781
:param credential: Credential needed for the client to connect to Azure. Required.
6882
:type credential: ~azure.core.credentials_async.AsyncTokenCredential
6983
:param subscription_id: The ID of the target subscription. Required.
7084
:type subscription_id: str
7185
:param base_url: Service URL. Default value is "https://management.azure.com".
7286
:type base_url: str
73-
:keyword api_version: Api Version. Default value is "2023-10-03-preview". Note that overriding
87+
:keyword api_version: Api Version. Default value is "2024-03-31-preview". Note that overriding
7488
this default value may result in unsupported behavior.
7589
:paramtype api_version: str
7690
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
@@ -111,6 +125,7 @@ def __init__(
111125
self._serialize = Serializer(client_models)
112126
self._deserialize = Deserializer(client_models)
113127
self._serialize.client_side_validation = False
128+
self.licenses = LicensesOperations(self._client, self._config, self._serialize, self._deserialize)
114129
self.machines = MachinesOperations(self._client, self._config, self._serialize, self._deserialize)
115130
self.machine_extensions = MachineExtensionsOperations(
116131
self._client, self._config, self._serialize, self._deserialize
@@ -123,6 +138,8 @@ def __init__(
123138
self.machine_run_commands = MachineRunCommandsOperations(
124139
self._client, self._config, self._serialize, self._deserialize
125140
)
141+
self.gateways = GatewaysOperations(self._client, self._config, self._serialize, self._deserialize)
142+
self.settings = SettingsOperations(self._client, self._config, self._serialize, self._deserialize)
126143
self.private_link_scopes = PrivateLinkScopesOperations(
127144
self._client, self._config, self._serialize, self._deserialize
128145
)
@@ -132,6 +149,9 @@ def __init__(
132149
self.private_endpoint_connections = PrivateEndpointConnectionsOperations(
133150
self._client, self._config, self._serialize, self._deserialize
134151
)
152+
self.network_security_perimeter_configurations = NetworkSecurityPerimeterConfigurationsOperations(
153+
self._client, self._config, self._serialize, self._deserialize
154+
)
135155

136156
def _send_request(
137157
self, request: HttpRequest, *, stream: bool = False, **kwargs: Any

sdk/hybridcompute/azure-mgmt-hybridcompute/azure/mgmt/hybridcompute/aio/operations/__init__.py

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

9+
from ._licenses_operations import LicensesOperations
910
from ._machines_operations import MachinesOperations
1011
from ._machine_extensions_operations import MachineExtensionsOperations
1112
from ._hybrid_compute_management_client_operations import HybridComputeManagementClientOperationsMixin
1213
from ._extension_metadata_operations import ExtensionMetadataOperations
1314
from ._operations import Operations
1415
from ._network_profile_operations import NetworkProfileOperations
1516
from ._machine_run_commands_operations import MachineRunCommandsOperations
17+
from ._gateways_operations import GatewaysOperations
18+
from ._settings_operations import SettingsOperations
1619
from ._private_link_scopes_operations import PrivateLinkScopesOperations
1720
from ._private_link_resources_operations import PrivateLinkResourcesOperations
1821
from ._private_endpoint_connections_operations import PrivateEndpointConnectionsOperations
22+
from ._network_security_perimeter_configurations_operations import NetworkSecurityPerimeterConfigurationsOperations
1923

2024
from ._patch import __all__ as _patch_all
2125
from ._patch import * # pylint: disable=unused-wildcard-import
2226
from ._patch import patch_sdk as _patch_sdk
2327

2428
__all__ = [
29+
"LicensesOperations",
2530
"MachinesOperations",
2631
"MachineExtensionsOperations",
2732
"HybridComputeManagementClientOperationsMixin",
2833
"ExtensionMetadataOperations",
2934
"Operations",
3035
"NetworkProfileOperations",
3136
"MachineRunCommandsOperations",
37+
"GatewaysOperations",
38+
"SettingsOperations",
3239
"PrivateLinkScopesOperations",
3340
"PrivateLinkResourcesOperations",
3441
"PrivateEndpointConnectionsOperations",
42+
"NetworkSecurityPerimeterConfigurationsOperations",
3543
]
3644
__all__.extend([p for p in _patch_all if p not in __all__])
3745
_patch_sdk()

sdk/hybridcompute/azure-mgmt-hybridcompute/azure/mgmt/hybridcompute/aio/operations/_extension_metadata_operations.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
# Code generated by Microsoft (R) AutoRest Code Generator.
77
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
88
# --------------------------------------------------------------------------
9-
from typing import Any, AsyncIterable, Callable, Dict, Optional, TypeVar
9+
import sys
10+
from typing import Any, AsyncIterable, Callable, Dict, Optional, Type, TypeVar
1011
import urllib.parse
1112

1213
from azure.core.async_paging import AsyncItemPaged, AsyncList
@@ -31,6 +32,10 @@
3132
from ...operations._extension_metadata_operations import build_get_request, build_list_request
3233
from .._vendor import HybridComputeManagementClientMixinABC
3334

35+
if sys.version_info >= (3, 9):
36+
from collections.abc import MutableMapping
37+
else:
38+
from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports
3439
T = TypeVar("T")
3540
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]
3641

@@ -72,7 +77,7 @@ async def get(
7277
:rtype: ~azure.mgmt.hybridcompute.models.ExtensionValue
7378
:raises ~azure.core.exceptions.HttpResponseError:
7479
"""
75-
error_map = {
80+
error_map: MutableMapping[int, Type[HttpResponseError]] = {
7681
401: ClientAuthenticationError,
7782
404: ResourceNotFoundError,
7883
409: ResourceExistsError,
@@ -141,7 +146,7 @@ def list(
141146
api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version))
142147
cls: ClsType[_models.ExtensionValueListResult] = kwargs.pop("cls", None)
143148

144-
error_map = {
149+
error_map: MutableMapping[int, Type[HttpResponseError]] = {
145150
401: ClientAuthenticationError,
146151
404: ResourceNotFoundError,
147152
409: ResourceExistsError,

0 commit comments

Comments
 (0)