diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/CHANGELOG.md b/sdk/computerecommender/azure-mgmt-computerecommender/CHANGELOG.md index 38060bf99360..9746db76bea2 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/CHANGELOG.md +++ b/sdk/computerecommender/azure-mgmt-computerecommender/CHANGELOG.md @@ -1,5 +1,19 @@ # Release History +## 1.0.0b3 (2026-08-28) + +### Features Added + + - Model `SkuMixPlacementResponse` added property `capacity_limits` + - Model `SkuMixPlacementResponse` added property `id` + - Added model `SkuMixPlacementCapacityLimit` + - Added enum `SkuMixPlacementCapacityLimitReason` + +### Breaking Changes + + - Model `SkuMixPlacementDeploymentChoice` deleted or renamed its instance variable `id` + - Model `SkuMixPlacementItem` deleted or renamed its instance variable `capacity_max` + ## 1.0.0b2 (2026-08-03) ### Features Added diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/_metadata.json b/sdk/computerecommender/azure-mgmt-computerecommender/_metadata.json index bd3366123dde..419cb7c01b69 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/_metadata.json +++ b/sdk/computerecommender/azure-mgmt-computerecommender/_metadata.json @@ -1,11 +1,11 @@ { - "apiVersion": "2026-05-05-preview", + "apiVersion": "2026-09-05-preview", "apiVersions": { - "Microsoft.Compute": "2026-05-05-preview" + "Microsoft.Compute": "2026-09-05-preview" }, - "commit": "57e7493ae28af7b6ad02338e7a038f06ed6c2203", + "commit": "397bf665c4d649b98bcfaf239c4b0a526301a03a", "repository_url": "https://github.com/Azure/azure-rest-api-specs", "typespec_src": "specification/compute/resource-manager/Microsoft.Compute/Recommender", - "emitterVersion": "0.63.3", - "httpClientPythonVersion": "^0.35.1" + "emitterVersion": "0.63.5", + "httpClientPythonVersion": "^0.36.0" } \ No newline at end of file diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/api.md b/sdk/computerecommender/azure-mgmt-computerecommender/api.md index 4b9f3b6869e3..41052c7b56e2 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/api.md +++ b/sdk/computerecommender/azure-mgmt-computerecommender/api.md @@ -80,7 +80,7 @@ namespace azure.mgmt.computerecommender.aio.operations ) -> None: ... @distributed_trace_async - @api_version_validation(method_added_on='2026-05-05-preview', params_added_on={'2026-05-05-preview': ['api_version', 'subscription_id', 'location', 'accept']}, api_versions_list=['2026-05-05-preview']) + @api_version_validation(method_added_on='2026-05-05-preview', params_added_on={'2026-05-05-preview': ['api_version', 'subscription_id', 'location', 'accept']}, api_versions_list=['2026-05-05-preview', '2026-09-05-preview']) async def get( self, location: str, @@ -341,6 +341,35 @@ namespace azure.mgmt.computerecommender.models def __init__(self, mapping: Mapping[str, Any]) -> None: ... + class azure.mgmt.computerecommender.models.SkuMixPlacementCapacityLimit(_Model): + limit: int + name: str + priority: Union[str, SkuMixPlacementPriority] + reason: Union[str, SkuMixPlacementCapacityLimitReason] + zone: Optional[str] + + @overload + def __init__( + self, + *, + limit: int, + name: str, + priority: Union[str, SkuMixPlacementPriority], + reason: Union[str, SkuMixPlacementCapacityLimitReason], + zone: Optional[str] = ... + ) -> None: ... + + @overload + def __init__(self, mapping: Mapping[str, Any]) -> None: ... + + + class azure.mgmt.computerecommender.models.SkuMixPlacementCapacityLimitReason(str, Enum, metaclass=CaseInsensitiveEnumMeta): + INSUFFICIENT_CAPACITY = "InsufficientCapacity" + INSUFFICIENT_QUOTA = "InsufficientQuota" + NONE = "None" + SKU_NOT_AVAILABLE = "SkuNotAvailable" + + class azure.mgmt.computerecommender.models.SkuMixPlacementCapacityProfile(_Model): allocation_strategy: Optional[Union[str, SkuMixPlacementAllocationStrategy]] capacity: int @@ -373,7 +402,6 @@ namespace azure.mgmt.computerecommender.models class azure.mgmt.computerecommender.models.SkuMixPlacementDeploymentChoice(_Model): - id: str score: int sku_split: list[SkuMixPlacementItem] @@ -381,7 +409,6 @@ namespace azure.mgmt.computerecommender.models def __init__( self, *, - id: str, score: int, sku_split: list[SkuMixPlacementItem] ) -> None: ... @@ -406,7 +433,6 @@ namespace azure.mgmt.computerecommender.models class azure.mgmt.computerecommender.models.SkuMixPlacementItem(_Model): capacity: int - capacity_max: Optional[int] name: str priority: Union[str, SkuMixPlacementPriority] zone: Optional[str] @@ -416,7 +442,6 @@ namespace azure.mgmt.computerecommender.models self, *, capacity: int, - capacity_max: Optional[int] = ..., name: str, priority: Union[str, SkuMixPlacementPriority], zone: Optional[str] = ... @@ -475,6 +500,8 @@ namespace azure.mgmt.computerecommender.models class azure.mgmt.computerecommender.models.SkuMixPlacementResponse(_Model): + capacity_limits: Optional[list[SkuMixPlacementCapacityLimit]] + id: str partial_fulfillment_reason: Union[str, SkuMixPlacementPartialFulfillmentReason] placement_choices: list[SkuMixPlacementDeploymentChoice] valid_until: Optional[datetime] @@ -483,6 +510,8 @@ namespace azure.mgmt.computerecommender.models def __init__( self, *, + capacity_limits: Optional[list[SkuMixPlacementCapacityLimit]] = ..., + id: str, partial_fulfillment_reason: Union[str, SkuMixPlacementPartialFulfillmentReason], placement_choices: list[SkuMixPlacementDeploymentChoice], valid_until: Optional[datetime] = ... @@ -651,7 +680,7 @@ namespace azure.mgmt.computerecommender.operations ) -> None: ... @distributed_trace - @api_version_validation(method_added_on='2026-05-05-preview', params_added_on={'2026-05-05-preview': ['api_version', 'subscription_id', 'location', 'accept']}, api_versions_list=['2026-05-05-preview']) + @api_version_validation(method_added_on='2026-05-05-preview', params_added_on={'2026-05-05-preview': ['api_version', 'subscription_id', 'location', 'accept']}, api_versions_list=['2026-05-05-preview', '2026-09-05-preview']) def get( self, location: str, diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/api.metadata.yml b/sdk/computerecommender/azure-mgmt-computerecommender/api.metadata.yml index 3a5d8f927b22..a78283672d03 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/api.metadata.yml +++ b/sdk/computerecommender/azure-mgmt-computerecommender/api.metadata.yml @@ -1,3 +1,3 @@ -apiMdSha256: 41bb8a33d1ba084319fc5347aabc0f8bafd5e5e0fe748c97653c569b45d914bc -parserVersion: 0.3.30 -pythonVersion: 3.13.14 +apiMdSha256: 7b895877a1f3550673e295f4e204b1507e9f83699a09a9b5006b412fa4ff0c08 +parserVersion: 0.3.31 +pythonVersion: 3.13.15 diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/apiview-properties.json b/sdk/computerecommender/azure-mgmt-computerecommender/apiview-properties.json index 7bd4017dbcc5..d754e0e3ceeb 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/apiview-properties.json +++ b/sdk/computerecommender/azure-mgmt-computerecommender/apiview-properties.json @@ -13,6 +13,7 @@ "azure.mgmt.computerecommender.models.PlacementScore": "Microsoft.Compute.PlacementScore", "azure.mgmt.computerecommender.models.ResourceSize": "Microsoft.Compute.ResourceSize", "azure.mgmt.computerecommender.models.SkuMixPlacementBase": "Microsoft.Compute.SkuMixPlacementBase", + "azure.mgmt.computerecommender.models.SkuMixPlacementCapacityLimit": "Microsoft.Compute.SkuMixPlacementCapacityLimit", "azure.mgmt.computerecommender.models.SkuMixPlacementCapacityProfile": "Microsoft.Compute.SkuMixPlacementCapacityProfile", "azure.mgmt.computerecommender.models.SkuMixPlacementDeploymentChoice": "Microsoft.Compute.SkuMixPlacementDeploymentChoice", "azure.mgmt.computerecommender.models.SkuMixPlacementInstanceDescription": "Microsoft.Compute.SkuMixPlacementInstanceDescription", @@ -32,6 +33,7 @@ "azure.mgmt.computerecommender.models.CreatedByType": "Azure.ResourceManager.CommonTypes.createdByType", "azure.mgmt.computerecommender.models.SkuMixPlacementPriority": "Microsoft.Compute.SkuMixPlacementPriority", "azure.mgmt.computerecommender.models.SkuMixPlacementPartialFulfillmentReason": "Microsoft.Compute.SkuMixPlacementPartialFulfillmentReason", + "azure.mgmt.computerecommender.models.SkuMixPlacementCapacityLimitReason": "Microsoft.Compute.SkuMixPlacementCapacityLimitReason", "azure.mgmt.computerecommender.models.SkuMixPlacementCapacityType": "Microsoft.Compute.SkuMixPlacementCapacityType", "azure.mgmt.computerecommender.models.SkuMixPlacementAllocationStrategy": "Microsoft.Compute.SkuMixPlacementAllocationStrategy", "azure.mgmt.computerecommender.models.SkuMixPlacementOSType": "Microsoft.Compute.SkuMixPlacementOSType", @@ -47,5 +49,5 @@ "azure.mgmt.computerecommender.operations.SpotPlacementScoresOperations.post": "Microsoft.Compute.ComputeDiagnosticBases.post", "azure.mgmt.computerecommender.aio.operations.SpotPlacementScoresOperations.post": "Microsoft.Compute.ComputeDiagnosticBases.post" }, - "CrossLanguageVersion": "51800132f656" + "CrossLanguageVersion": "6abdb790f35f" } \ No newline at end of file diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_client.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_client.py index 013bae052940..d3e924e7a1be 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_client.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_client.py @@ -52,7 +52,7 @@ class RecommenderMgmtClient: # pylint: disable=docstring-keyword-should-match-k None. :paramtype cloud_setting: ~azure.core.AzureClouds :keyword api_version: The API version to use for this operation. Known values are - "2026-05-05-preview" and None. Default value is None. If not set, the operation's default API + "2026-09-05-preview" and None. Default value is None. If not set, the operation's default API version will be used. Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_configuration.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_configuration.py index 39030347b4c9..5b0ed3dd953f 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_configuration.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_configuration.py @@ -35,7 +35,7 @@ class RecommenderMgmtClientConfiguration: # pylint: disable=too-many-instance-a None. :type cloud_setting: ~azure.core.AzureClouds :keyword api_version: The API version to use for this operation. Known values are - "2026-05-05-preview" and None. Default value is None. If not set, the operation's default API + "2026-09-05-preview" and None. Default value is None. If not set, the operation's default API version will be used. Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str @@ -49,7 +49,7 @@ def __init__( cloud_setting: Optional["AzureClouds"] = None, **kwargs: Any ) -> None: - api_version: str = kwargs.pop("api_version", "2026-05-05-preview") + api_version: str = kwargs.pop("api_version", "2026-09-05-preview") if credential is None: raise ValueError("Parameter 'credential' must not be None.") diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_patch.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_patch.py index 87676c65a8f0..ea765788358a 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_patch.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_patch.py @@ -8,7 +8,6 @@ Follow our quickstart for examples: https://aka.ms/azsdk/python/dpcodegen/python/customize """ - __all__: list[str] = [] # Add all objects you want publicly available to users at this package level diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_version.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_version.py index bbcd28b4aa67..c43fdbc2e239 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_version.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "1.0.0b2" +VERSION = "1.0.0b3" diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_client.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_client.py index 73791ace46c3..f32c98823b41 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_client.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_client.py @@ -52,7 +52,7 @@ class RecommenderMgmtClient: # pylint: disable=docstring-keyword-should-match-k None. :paramtype cloud_setting: ~azure.core.AzureClouds :keyword api_version: The API version to use for this operation. Known values are - "2026-05-05-preview" and None. Default value is None. If not set, the operation's default API + "2026-09-05-preview" and None. Default value is None. If not set, the operation's default API version will be used. Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_configuration.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_configuration.py index 583ce902c5b9..b53bcbabdde2 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_configuration.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_configuration.py @@ -35,7 +35,7 @@ class RecommenderMgmtClientConfiguration: # pylint: disable=too-many-instance-a None. :type cloud_setting: ~azure.core.AzureClouds :keyword api_version: The API version to use for this operation. Known values are - "2026-05-05-preview" and None. Default value is None. If not set, the operation's default API + "2026-09-05-preview" and None. Default value is None. If not set, the operation's default API version will be used. Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str @@ -49,7 +49,7 @@ def __init__( cloud_setting: Optional["AzureClouds"] = None, **kwargs: Any ) -> None: - api_version: str = kwargs.pop("api_version", "2026-05-05-preview") + api_version: str = kwargs.pop("api_version", "2026-09-05-preview") if credential is None: raise ValueError("Parameter 'credential' must not be None.") diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_patch.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_patch.py index 87676c65a8f0..ea765788358a 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_patch.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/_patch.py @@ -8,7 +8,6 @@ Follow our quickstart for examples: https://aka.ms/azsdk/python/dpcodegen/python/customize """ - __all__: list[str] = [] # Add all objects you want publicly available to users at this package level diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_operations.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_operations.py index 7aeb0ea98317..497e22d612d0 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_operations.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_operations.py @@ -181,7 +181,7 @@ def __init__(self, *args, **kwargs) -> None: @api_version_validation( method_added_on="2026-05-05-preview", params_added_on={"2026-05-05-preview": ["api_version", "subscription_id", "location", "accept"]}, - api_versions_list=["2026-05-05-preview"], + api_versions_list=["2026-05-05-preview", "2026-09-05-preview"], ) async def get(self, location: str, **kwargs: Any) -> _models.SkuMixPlacementBase: """Gets SkuMixPlacement scoring metadata. @@ -326,7 +326,7 @@ async def post( params_added_on={ "2026-05-05-preview": ["api_version", "subscription_id", "location", "content_type", "accept"] }, - api_versions_list=["2026-05-05-preview"], + api_versions_list=["2026-05-05-preview", "2026-09-05-preview"], ) async def post( self, diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_patch.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_patch.py index 87676c65a8f0..ea765788358a 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_patch.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/aio/operations/_patch.py @@ -8,7 +8,6 @@ Follow our quickstart for examples: https://aka.ms/azsdk/python/dpcodegen/python/customize """ - __all__: list[str] = [] # Add all objects you want publicly available to users at this package level diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/__init__.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/__init__.py index af3fb875f8b9..771fdfb53dd8 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/__init__.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/__init__.py @@ -26,6 +26,7 @@ Resource, ResourceSize, SkuMixPlacementBase, + SkuMixPlacementCapacityLimit, SkuMixPlacementCapacityProfile, SkuMixPlacementDeploymentChoice, SkuMixPlacementInstanceDescription, @@ -47,6 +48,7 @@ CreatedByType, Origin, SkuMixPlacementAllocationStrategy, + SkuMixPlacementCapacityLimitReason, SkuMixPlacementCapacityType, SkuMixPlacementOSType, SkuMixPlacementPartialFulfillmentReason, @@ -70,6 +72,7 @@ "Resource", "ResourceSize", "SkuMixPlacementBase", + "SkuMixPlacementCapacityLimit", "SkuMixPlacementCapacityProfile", "SkuMixPlacementDeploymentChoice", "SkuMixPlacementInstanceDescription", @@ -88,6 +91,7 @@ "CreatedByType", "Origin", "SkuMixPlacementAllocationStrategy", + "SkuMixPlacementCapacityLimitReason", "SkuMixPlacementCapacityType", "SkuMixPlacementOSType", "SkuMixPlacementPartialFulfillmentReason", diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_enums.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_enums.py index 505d5832c4ca..bc2be2154f5d 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_enums.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_enums.py @@ -56,6 +56,20 @@ class SkuMixPlacementAllocationStrategy(str, Enum, metaclass=CaseInsensitiveEnum """VMs allocated to optimize for lowest eviction rate (Spot only).""" +class SkuMixPlacementCapacityLimitReason(str, Enum, metaclass=CaseInsensitiveEnumMeta): + """Reason the capacity limit for a (VM size, zone) is below the requested capacity.""" + + NONE = "None" + """The full requested capacity is available for this (VM size, zone).""" + INSUFFICIENT_CAPACITY = "InsufficientCapacity" + """Allocable capacity bounded the limit below the requested capacity.""" + INSUFFICIENT_QUOTA = "InsufficientQuota" + """Quota bounded the limit below the requested capacity. Takes precedence when both capacity and + quota are insufficient.""" + SKU_NOT_AVAILABLE = "SkuNotAvailable" + """This VM size is not available in this zone for the subscription.""" + + class SkuMixPlacementCapacityType(str, Enum, metaclass=CaseInsensitiveEnumMeta): """The unit type for the capacity value.""" diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_models.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_models.py index 8fd103cae0af..94a4ce478c77 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_models.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_models.py @@ -417,6 +417,70 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: super().__init__(*args, **kwargs) +class SkuMixPlacementCapacityLimit(_Model): # pylint: disable=docstring-keyword-should-match-keyword-only + """Capacity availability for a single requested (VM size, zone) combination, independent of the + recommended placement. + + :ivar name: VM size name (e.g. Standard_D2s_v3). Required. + :vartype name: str + :ivar priority: Priority of this entry (Regular or Spot). Required. Known values are: "Regular" + and "Spot". + :vartype priority: str or ~azure.mgmt.computerecommender.models.SkuMixPlacementPriority + :ivar zone: Logical zone (e.g. "1", "2", "3"). Omitted or empty for regional requests. + :vartype zone: str + :ivar limit: Upper bound, in VMs, on how much capacity can be allocated for this (VM size, + zone): the smallest of the requested capacity, the available capacity, and the available quota, + but never below the capacity already recommended for the slot. 0 when nothing is available. + Required. + :vartype limit: int + :ivar reason: Why the limit is below the requested capacity, or None when the request is fully + available. Required. Known values are: "None", "InsufficientCapacity", "InsufficientQuota", and + "SkuNotAvailable". + :vartype reason: str or + ~azure.mgmt.computerecommender.models.SkuMixPlacementCapacityLimitReason + """ + + name: str = rest_field(visibility=["read", "create", "update", "delete", "query"]) + """VM size name (e.g. Standard_D2s_v3). Required.""" + priority: Union[str, "_models.SkuMixPlacementPriority"] = rest_field( + visibility=["read", "create", "update", "delete", "query"] + ) + """Priority of this entry (Regular or Spot). Required. Known values are: \"Regular\" and \"Spot\".""" + zone: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"]) + """Logical zone (e.g. \"1\", \"2\", \"3\"). Omitted or empty for regional requests.""" + limit: int = rest_field(visibility=["read", "create", "update", "delete", "query"]) + """Upper bound, in VMs, on how much capacity can be allocated for this (VM size, zone): the + smallest of the requested capacity, the available capacity, and the available quota, but never + below the capacity already recommended for the slot. 0 when nothing is available. Required.""" + reason: Union[str, "_models.SkuMixPlacementCapacityLimitReason"] = rest_field( + visibility=["read", "create", "update", "delete", "query"] + ) + """Why the limit is below the requested capacity, or None when the request is fully available. + Required. Known values are: \"None\", \"InsufficientCapacity\", \"InsufficientQuota\", and + \"SkuNotAvailable\".""" + + @overload + def __init__( + self, + *, + name: str, + priority: Union[str, "_models.SkuMixPlacementPriority"], + limit: int, + reason: Union[str, "_models.SkuMixPlacementCapacityLimitReason"], + zone: Optional[str] = None, + ) -> None: ... + + @overload + def __init__(self, mapping: Mapping[str, Any]) -> None: + """ + :param mapping: raw JSON to initialize the model. + :type mapping: Mapping[str, Any] + """ + + def __init__(self, *args: Any, **kwargs: Any) -> None: + super().__init__(*args, **kwargs) + + class SkuMixPlacementCapacityProfile(_Model): # pylint: disable=docstring-keyword-should-match-keyword-only """Capacity-related properties for the placement request. @@ -430,8 +494,7 @@ class SkuMixPlacementCapacityProfile(_Model): # pylint: disable=docstring-keywo :ivar priority: The priority of the VMs to allocate. Required. Known values are: "Regular" and "Spot". :vartype priority: str or ~azure.mgmt.computerecommender.models.SkuMixPlacementPriority - :ivar spot_priority_profile: Required when priority is Spot. Contains spot-specific - configuration. + :ivar spot_priority_profile: Contains spot-specific configuration. :vartype spot_priority_profile: ~azure.mgmt.computerecommender.models.SkuMixPlacementSpotPriorityProfile :ivar allocation_strategy: The allocation strategy for determining the optimal SKU split. Known @@ -459,7 +522,7 @@ class SkuMixPlacementCapacityProfile(_Model): # pylint: disable=docstring-keywo spot_priority_profile: Optional["_models.SkuMixPlacementSpotPriorityProfile"] = rest_field( name="spotPriorityProfile", visibility=["read", "create", "update", "delete", "query"] ) - """Required when priority is Spot. Contains spot-specific configuration.""" + """Contains spot-specific configuration.""" allocation_strategy: Optional[Union[str, "_models.SkuMixPlacementAllocationStrategy"]] = rest_field( name="allocationStrategy", visibility=["read", "create", "update", "delete", "query"] ) @@ -502,8 +565,6 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: class SkuMixPlacementDeploymentChoice(_Model): # pylint: disable=docstring-keyword-should-match-keyword-only """A single deployment choice recommendation. - :ivar id: Unique identifier for this deployment choice. Required. - :vartype id: str :ivar score: Placement score from 0 to 9 (inclusive). Higher is better. Required. :vartype score: int :ivar sku_split: The list of VM size / zone allocations that make up this deployment choice. @@ -511,8 +572,6 @@ class SkuMixPlacementDeploymentChoice(_Model): # pylint: disable=docstring-keyw :vartype sku_split: list[~azure.mgmt.computerecommender.models.SkuMixPlacementItem] """ - id: str = rest_field(visibility=["read", "create", "update", "delete", "query"]) - """Unique identifier for this deployment choice. Required.""" score: int = rest_field(visibility=["read", "create", "update", "delete", "query"]) """Placement score from 0 to 9 (inclusive). Higher is better. Required.""" sku_split: list["_models.SkuMixPlacementItem"] = rest_field( @@ -524,7 +583,6 @@ class SkuMixPlacementDeploymentChoice(_Model): # pylint: disable=docstring-keyw def __init__( self, *, - id: str, # pylint: disable=redefined-builtin score: int, sku_split: list["_models.SkuMixPlacementItem"], ) -> None: ... @@ -580,8 +638,6 @@ class SkuMixPlacementItem(_Model): # pylint: disable=docstring-keyword-should-m :vartype priority: str or ~azure.mgmt.computerecommender.models.SkuMixPlacementPriority :ivar capacity: Lower range of recommended allocation capacity. Required. :vartype capacity: int - :ivar capacity_max: Upper range of recommended allocation capacity. - :vartype capacity_max: int :ivar zone: Logical zone (e.g. "1", "2", "3"). Omitted or empty for regional deployments. :vartype zone: str """ @@ -595,10 +651,6 @@ class SkuMixPlacementItem(_Model): # pylint: disable=docstring-keyword-should-m \"Spot\".""" capacity: int = rest_field(visibility=["read", "create", "update", "delete", "query"]) """Lower range of recommended allocation capacity. Required.""" - capacity_max: Optional[int] = rest_field( - name="capacityMax", visibility=["read", "create", "update", "delete", "query"] - ) - """Upper range of recommended allocation capacity.""" zone: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"]) """Logical zone (e.g. \"1\", \"2\", \"3\"). Omitted or empty for regional deployments.""" @@ -609,7 +661,6 @@ def __init__( name: str, priority: Union[str, "_models.SkuMixPlacementPriority"], capacity: int, - capacity_max: Optional[int] = None, zone: Optional[str] = None, ) -> None: ... @@ -704,6 +755,10 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: class SkuMixPlacementResponse(_Model): # pylint: disable=docstring-keyword-should-match-keyword-only """Sku Mix Placement API response. + :ivar id: Unique identifier for this placement response, including responses that contain no + placement choices. Replaces the per-choice id that was present on placementChoices in earlier + API versions. Required. + :vartype id: str :ivar placement_choices: List of placement choice recommendations. Required. :vartype placement_choices: list[~azure.mgmt.computerecommender.models.SkuMixPlacementDeploymentChoice] @@ -715,8 +770,18 @@ class SkuMixPlacementResponse(_Model): # pylint: disable=docstring-keyword-shou "InsufficientQuota". :vartype partial_fulfillment_reason: str or ~azure.mgmt.computerecommender.models.SkuMixPlacementPartialFulfillmentReason + :ivar capacity_limits: Capacity availability for each requested (VM size, zone) combination, + independent of the recommended placement. An entry is present for every requested combination, + including those excluded by capacity or quota. Only returned for requests that describe + instances by VM sizes. + :vartype capacity_limits: + list[~azure.mgmt.computerecommender.models.SkuMixPlacementCapacityLimit] """ + id: str = rest_field(visibility=["read", "create", "update", "delete", "query"]) + """Unique identifier for this placement response, including responses that contain no placement + choices. Replaces the per-choice id that was present on placementChoices in earlier API + versions. Required.""" placement_choices: list["_models.SkuMixPlacementDeploymentChoice"] = rest_field( name="placementChoices", visibility=["read", "create", "update", "delete", "query"] ) @@ -731,14 +796,22 @@ class SkuMixPlacementResponse(_Model): # pylint: disable=docstring-keyword-shou ) """Indicates whether the response is a complete or partial fulfillment. Required. Known values are: \"None\", \"InsufficientCapacity\", and \"InsufficientQuota\".""" + capacity_limits: Optional[list["_models.SkuMixPlacementCapacityLimit"]] = rest_field( + name="capacityLimits", visibility=["read", "create", "update", "delete", "query"] + ) + """Capacity availability for each requested (VM size, zone) combination, independent of the + recommended placement. An entry is present for every requested combination, including those + excluded by capacity or quota. Only returned for requests that describe instances by VM sizes.""" @overload def __init__( self, *, + id: str, # pylint: disable=redefined-builtin placement_choices: list["_models.SkuMixPlacementDeploymentChoice"], partial_fulfillment_reason: Union[str, "_models.SkuMixPlacementPartialFulfillmentReason"], valid_until: Optional[datetime.datetime] = None, + capacity_limits: Optional[list["_models.SkuMixPlacementCapacityLimit"]] = None, ) -> None: ... @overload @@ -753,7 +826,7 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: class SkuMixPlacementSpotPriorityProfile(_Model): # pylint: disable=docstring-keyword-should-match-keyword-only - """Spot priority configuration. Required when priority is Spot. + """Spot priority configuration. :ivar max_price_per_vm: Maximum price per VM the customer is willing to pay. Default: -1 (no price restriction). diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_patch.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_patch.py index 87676c65a8f0..ea765788358a 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_patch.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/models/_patch.py @@ -8,7 +8,6 @@ Follow our quickstart for examples: https://aka.ms/azsdk/python/dpcodegen/python/customize """ - __all__: list[str] = [] # Add all objects you want publicly available to users at this package level diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_operations.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_operations.py index 0f4ecf7161dc..bbcebb621506 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_operations.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_operations.py @@ -48,7 +48,7 @@ def build_operations_list_request(**kwargs: Any) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-05-05-preview")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-09-05-preview")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -69,7 +69,7 @@ def build_sku_mix_placement_scores_get_request( # pylint: disable=name-too-long _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-05-05-preview")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-09-05-preview")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -97,7 +97,7 @@ def build_sku_mix_placement_scores_post_request( # pylint: disable=name-too-lon _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-05-05-preview")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-09-05-preview")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -124,7 +124,7 @@ def build_spot_placement_scores_get_request(location: str, subscription_id: str, _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-05-05-preview")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-09-05-preview")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -150,7 +150,7 @@ def build_spot_placement_scores_post_request(location: str, subscription_id: str _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-05-05-preview")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2026-09-05-preview")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -306,7 +306,7 @@ def __init__(self, *args, **kwargs) -> None: @api_version_validation( method_added_on="2026-05-05-preview", params_added_on={"2026-05-05-preview": ["api_version", "subscription_id", "location", "accept"]}, - api_versions_list=["2026-05-05-preview"], + api_versions_list=["2026-05-05-preview", "2026-09-05-preview"], ) def get(self, location: str, **kwargs: Any) -> _models.SkuMixPlacementBase: """Gets SkuMixPlacement scoring metadata. @@ -451,7 +451,7 @@ def post( params_added_on={ "2026-05-05-preview": ["api_version", "subscription_id", "location", "content_type", "accept"] }, - api_versions_list=["2026-05-05-preview"], + api_versions_list=["2026-05-05-preview", "2026-09-05-preview"], ) def post( self, diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_patch.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_patch.py index 87676c65a8f0..ea765788358a 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_patch.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/operations/_patch.py @@ -8,7 +8,6 @@ Follow our quickstart for examples: https://aka.ms/azsdk/python/dpcodegen/python/customize """ - __all__: list[str] = [] # Add all objects you want publicly available to users at this package level diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/types.py b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/types.py index 6a77a2dc3d24..a564d937ba40 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/types.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/azure/mgmt/computerecommender/types.py @@ -42,8 +42,7 @@ class SkuMixPlacementCapacityProfile(TypedDict, total=False): :ivar priority: The priority of the VMs to allocate. Required. Known values are: "Regular" and "Spot". :vartype priority: Union[str, "SkuMixPlacementPriority"] - :ivar spotPriorityProfile: Required when priority is Spot. Contains spot-specific - configuration. + :ivar spotPriorityProfile: Contains spot-specific configuration. :vartype spotPriorityProfile: "SkuMixPlacementSpotPriorityProfile" :ivar allocationStrategy: The allocation strategy for determining the optimal SKU split. Known values are: "LowestPrice", "Prioritized", and "EvictionOptimized". @@ -62,7 +61,7 @@ class SkuMixPlacementCapacityProfile(TypedDict, total=False): priority: Required[Union[str, "SkuMixPlacementPriority"]] """The priority of the VMs to allocate. Required. Known values are: \"Regular\" and \"Spot\".""" spotPriorityProfile: "SkuMixPlacementSpotPriorityProfile" - """Required when priority is Spot. Contains spot-specific configuration.""" + """Contains spot-specific configuration.""" allocationStrategy: Union[str, "SkuMixPlacementAllocationStrategy"] """The allocation strategy for determining the optimal SKU split. Known values are: \"LowestPrice\", \"Prioritized\", and \"EvictionOptimized\".""" @@ -107,7 +106,7 @@ class SkuMixPlacementRequest(TypedDict, total=False): class SkuMixPlacementSpotPriorityProfile(TypedDict, total=False): - """Spot priority configuration. Required when priority is Spot. + """Spot priority configuration. :ivar maxPricePerVm: Maximum price per VM the customer is willing to pay. Default: -1 (no price restriction). diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_sku_mix_placement_scores.py b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_sku_mix_placement_scores.py index 64ce3c3421b8..4d4ddf76fa20 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_sku_mix_placement_scores.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_sku_mix_placement_scores.py @@ -50,6 +50,6 @@ def main(): print(response) -# x-ms-original-file: 2026-05-05-preview/GenerateSkuMixPlacementScores.json +# x-ms-original-file: 2026-09-05-preview/GenerateSkuMixPlacementScores.json if __name__ == "__main__": main() diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_spot_placement_scores.py b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_spot_placement_scores.py index 0dd7fa73c7e8..4944d1d4489b 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_spot_placement_scores.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/generate_spot_placement_scores.py @@ -42,6 +42,6 @@ def main(): print(response) -# x-ms-original-file: 2026-05-05-preview/GenerateSpotPlacementScores.json +# x-ms-original-file: 2026-09-05-preview/GenerateSpotPlacementScores.json if __name__ == "__main__": main() diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_sku_mix_placement_scores.py b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_sku_mix_placement_scores.py index fd81c44f02bb..f5a24d3be5c0 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_sku_mix_placement_scores.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_sku_mix_placement_scores.py @@ -36,6 +36,6 @@ def main(): print(response) -# x-ms-original-file: 2026-05-05-preview/GetSkuMixPlacementScores.json +# x-ms-original-file: 2026-09-05-preview/GetSkuMixPlacementScores.json if __name__ == "__main__": main() diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_spot_placement_scores.py b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_spot_placement_scores.py index e0e3353ccccb..d99bfbf17c33 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_spot_placement_scores.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/get_spot_placement_scores.py @@ -36,6 +36,6 @@ def main(): print(response) -# x-ms-original-file: 2026-05-05-preview/GetSpotPlacementScores.json +# x-ms-original-file: 2026-09-05-preview/GetSpotPlacementScores.json if __name__ == "__main__": main() diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_maximum_set_gen.py b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_maximum_set_gen.py index 0af1ef1b62e7..40cf7a2237bc 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_maximum_set_gen.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_maximum_set_gen.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: 2026-05-05-preview/Operations_List_MaximumSet_Gen.json +# x-ms-original-file: 2026-09-05-preview/Operations_List_MaximumSet_Gen.json if __name__ == "__main__": main() diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_minimum_set_gen.py b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_minimum_set_gen.py index 933bba67d442..6cebfc189bd3 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_minimum_set_gen.py +++ b/sdk/computerecommender/azure-mgmt-computerecommender/generated_samples/operations_list_minimum_set_gen.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: 2026-05-05-preview/Operations_List_MinimumSet_Gen.json +# x-ms-original-file: 2026-09-05-preview/Operations_List_MinimumSet_Gen.json if __name__ == "__main__": main() diff --git a/sdk/computerecommender/azure-mgmt-computerecommender/tsp-location.yaml b/sdk/computerecommender/azure-mgmt-computerecommender/tsp-location.yaml index c2b0d6eea0b7..aa96b2f9ddb2 100644 --- a/sdk/computerecommender/azure-mgmt-computerecommender/tsp-location.yaml +++ b/sdk/computerecommender/azure-mgmt-computerecommender/tsp-location.yaml @@ -1,4 +1,4 @@ directory: specification/compute/resource-manager/Microsoft.Compute/Recommender -commit: 57e7493ae28af7b6ad02338e7a038f06ed6c2203 +commit: 397bf665c4d649b98bcfaf239c4b0a526301a03a repo: Azure/azure-rest-api-specs additionalDirectories: